-
Notifications
You must be signed in to change notification settings - Fork 437
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Chew Cheng Yap] iP #42
Open
CodyChew
wants to merge
71
commits into
nus-cs2103-AY2021S1:master
Choose a base branch
from
CodyChew:master
base: master
Could not load branches
Branch not found: {{ refName }}
Could not load tags
Nothing to show
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-skeletal version of Dukenizer chatbot -Included echoing of commands and exits when user types "bye"
-Add items into a list -display list when called
-added task class -show active/done tasks
-Included Todo, Event and Deadline Class -Each task are labeled with the starting alphabet
Included runtest.bat
-now checks for tick/cross correctly
-Additional method to throw DukeException while checking instruction line -todo, deadline, event cannot be empty -done must have more than 1 argument separated with space, is number specified cannot be more than Task list -Many more exceptions have yet to be implemented
-All exceptions are handled when parsing the instruction -leading and trailing white spaces are stripped for every line following commands: list: -checks for no other inputs, (only "list") done: -checks for more than 1 input separated by space -checks for second input being a valid number and in the following format 'done <item number>' todo: -checks for no other inputs, (only "todo") deadline: -checks for 'deadline <description> /by <time>' format event: -checks for 'event <description> /at <time>' format
-added delete task from list -delete exceptions uses same checks as done exceptions
-shifted execution of instruction out of main method into read instruction method -separated delete and done logic for more customisations in the future
Let's write to a relative file path to a text file Dukenizer.txt. Every time the list updates, the file is written again. This is to easily get the full list string everytime the list is updated without having to process line by line when writing to the file.
Represent DataTime as an object rather than a string for manipulation. Let's store a LocalDateTime obejct for the Deadline and Event task. Able to format its output easily. Reference to validation for correct dates and time format https://stackoverflow.com/questions/2149680/regex-date-format-validation-on-java https://www.geeksforgeeks.org/how-to-validate-time-in-24-hour-format-using-regular-expression/
# Conflicts: # src/main/java/Duke.java
…lasses Classes have closely related code can be extracted into a single class. It reduces the complexity of viewing things. Ui class: deals with interactions with the user. Storage class: deals with loading tasks from the file and saving tasks in the file. Parser class: deals with making sense of the user command. TaskList class: contains the task list. It has operations to manipulate tasks in the list and get data from it. Command class: abstract Command class to allow us to use polymorphism when dealing with different commands
Organize class types into packages for easier management packages: -Duke -Duke.command -Duke.exception -Duke.parser -Duke.storage -Duke.task -Duke.ui
DukeException classes
Refer to Java coding standard https://se-education.org/guides/conventions/java/index.html
Give users a way to find a task from its description with a search term. Let's add a FindCommand class and updated Parser to accomodate find command keyword.
# Conflicts: # src/main/java/duke/command/ListCommand.java # src/main/java/duke/storage/Storage.java
# Conflicts: # src/main/java/duke/command/FindCommand.java
…nto branch-A-Gradle
Task done attribute makes use of UTF-8 encoding for task description. Let's configure Gradle compiler encoding to 'UTF-8'. Refer to article on setting UTF-8 properly in gradle: https://www.thetopsites.net/article/58616121.shtml Refer to this discussion on setting up UTF-8 to gradle: nus-cs2103-AY2021S1/forum#95
# Conflicts: # src/main/java/duke/task/TaskList.java
Refactor code to improve code quality
Refactor to use Java Streams
JUnit tests are used in this project.
Able to add notes and delete notes in a separate note list.
help command enables users to view all available commands for improved user experience.
Let's differentiate user's and Dukenizer's dialog box. User's box is now blue while Dukenizer's box is yellow.
Remove logo in greeting message as there is inconsistent formatting. Window size has increased and dialog box now has a consistent size for better viewing.
Program now shuts down on exit command. Let's return the exit message to the user and then delay for a while before closing the window. Refer to this documentation on the preferred way to terminate a JavaFX Application: https://docs.oracle.com/javase/8/javafx/api/javafx/application/Application.html
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.