Skip to content
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

[Qin Nanxin] iP #572

Open
wants to merge 76 commits into
base: master
Choose a base branch
from
Open

Conversation

InfiBeyond
Copy link

@InfiBeyond InfiBeyond commented Sep 7, 2023

Duke Max

“Hi, I am Duke Max. Your personal task management companion."

Duke Max[ frees your mind of having to remember things you need to do. It's,

  • text-based
  • easy to learn
  • FAST SUPER FAST to use

All you need to do is,

  1. download it from here.
  2. double-click it.
  3. add your tasks.
  4. let it manage your tasks for you 😉

And it is FREE!

Features:

  • Managing tasks
  • Managing deadlines (coming soon)
  • Reminders (coming soon)

If you Java programmer, you can use it to practice Java too. Here's the main method:

public class Main {
    public static void main(String[] args) {
        Application.launch(MainApp.class, args);
    }
}

damithc and others added 18 commits August 9, 2023 02:16
(a) Changed chatbot name form Duke to Edna
(b) Implement an initial skeletal version
Improve the skeletal version of Edna so that it echos commands entered by the user, and exits when the user types the command bye.
Add the ability to store whatever text entered by the user and display them back to the user when requested.
(a) Create Task class.
(b) Add the ability to mark tasks as done.
(c) Add the ability to change the status back to not done.
Add support for tracking three types of tasks:
ToDos: tasks without any date/time attached to it e.g., visit new theme park
Deadlines: tasks that need to be done before a specific date/time e.g., submit report by 11/10/2019 5pm
Events: tasks that start at a specific date/time and ends at a specific date/time
e.g., (a) team project meeting 2/10/2019 2-4pm (b) orientation week 4/10/2019 to 11/10/2019

* Fixed Level 3 error for mixing up "X" and " " for marked and unmarked tasks.
Use the input/output redirection technique to semi-automate the testing of Duke.
Teach the chatbot to deal with errors such as incorrect inputs entered by the user.

Use Exceptions to handle errors
Define a class DukeException to represent exceptions specific to Duke.
Add support for deleting tasks from the list.
Previously missed this file during git push.
- Unable figure out why my computer cannot open the previous files
- Attempt to clone work from GitHub  didn't work

Level 0. Rename, Greet, Exit
(a) Rename chatbot to "Edna-Duke".
(b) Implement an initial skeletal version of the it that simply greets the user and exits.
Improve the skeletal version of Duke so that it echos commands entered by the user, and exits when the user types the command bye.
Add the ability to store whatever text entered by the user and display them back to the user when requested.
Add the ability to mark tasks as done. Optionally, add the ability to change the status back to not done.
Add support for tracking three types of tasks:
- ToDos: tasks without any date/time attached to it e.g., visit new theme park
- Deadlines: tasks that need to be done before a specific date/time e.g., submit report by 11/10/2019 5pm
- Events: tasks that start at a specific date/time and ends at a specific date/time
  e.g., (a) team project meeting 2/10/2019 2-4pm (b) orientation week 4/10/2019 to 11/10/2019
Teach the chatbot to deal with errors such as incorrect inputs entered by the user.
Add support for deleting tasks from the list.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall good job! Good use of abstraction using the Task class! However, it might be a better idea to have even more abstraction through the addition of a UI class that handles all the printing and a TaskList class that handles the list of Tasks.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The indentation for the case blocks inside the switch statement within the try block does not follow the coding standard


public static void exit() {
System.out.println("Bye. Hope to see you again soon!");
System.out.println(partition);
}
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indentation & Formatting:

The code seems to be properly indented, which makes it easier to read.
The consistent use of brackets {} and their placement adheres to the Java coding conventions.
Variable Naming:

Names like input, eventCommand, and ddlCommand are meaningful, but some variables like ddl could have a more descriptive name.
Variables should be named in a manner that makes their purpose clear. For instance, ddl might be better named as deadlineDetails or similar.
sc has not been defined in the given snippet, so it's unclear what it represents. If it's a Scanner object, a more intuitive name like scanner might be more appropriate.

public String getStatus() {
return "[To-Do]" + super.getStatus();
}
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This program has only finished Week1-2 tasks, more OOP should be added

@@ -26,6 +26,10 @@ public static void main(String[] args) {
int unmarkItem = sc.nextInt();
taskList.get(unmarkItem - 1).markUndone();
break;
case "delete":
Copy link

@andrefoo andrefoo Sep 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider making inputs case-insensitive!

This way, if I requested to add a todo writing: tOdO it would still add the task into the list.
Try using 'String' 's equalsIgnoreCase() method compares two strings, ignoring lower case and upper case differences.

Copy link

@andrefoo andrefoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, some minor amendments needed that's all.

public class Duke {
public static String partition = "------------------------------------------------------------";

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider changing 'partition' to a final variable as it does not change, as well as fully capitalising the variable name to be 'PARTITION'

Save the tasks in the hard disk automatically whenever the task list changes. Load the data from the hard disk when the chatbot starts up.
* branch-Level-7:
  [Level 7. Save] Save the tasks in the hard disk automatically whenever the task list changes. Load the data from the hard disk when the chatbot starts up.
Teach the chatbot how to understand dates and times. For example, if the command is deadline return book /by 2/12/2019 1800, the chatbot should understand 2/12/2019 1800 as 2nd of December 2019, 6pm, instead of treating it as just a String.
* branch-Level-8:
  [Level 8. Dates and Times Teach the chatbot how to understand dates and times. For example, if the command is deadline return book /by 2/12/2019 1800, the chatbot should understand 2/12/2019 1800 as 2nd of December 2019, 6pm, instead of treating it as just a String.
Teach the chatbot how to understand dates and times. For example, if the command is deadline return book /by 2/12/2019 1800, the chatbot should understand 2/12/2019 1800 as 2nd of December 2019, 6pm, instead of treating it as just a String.
* branch-Level-8:
  [Level 8. Dates and Times] Teach the chatbot how to understand dates and times. For example, if the command is deadline return book /by 2/12/2019 1800, the chatbot should understand 2/12/2019 1800 as 2nd of December 2019, 6pm, instead of treating it as just a String.
}

catch (DukeException e) {
System.out.println(e.getMessage());

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think your method is too long here. Maybe try to create some other methods?😎

InfiBeyond and others added 30 commits September 28, 2023 15:09
* branch-Level-10:
  Add MainWindow.java
  [Level 10. GUI] Add a GUI to the chatbot. Use the JavaFX technology to implement the GUI.
  [Level 10. GUI] Initialize a GUI to the chatbot.
This bundles JavaFX with the JAR file. This makes sure that the application will work in computers that don't have JavaFX installed.

Generating a new JAR file improves the user inclusivity.
Use assert feature (not JUnit assertions) to document important assumptions that should hold at various points in the code.
Use checkStyle to detect coding style violations. Update file to ix styling issue and improve user readability.
[A-CheckStyle] Improve Code Quality
Add the ability to recognize and deal with duplicate items.
Warn users when attempting to add a new task with the same task description with existing task.
* branch-C-DetectDuplicates:
  [C-DetectDuplicates]
* branch-A-BetterGui:
  Fix GUI for display text by changing height and width.

# Conflicts:
#	src/main/java/duke/tasks/Task.java
Fix height of dialog box to custom user input and bot reply length.
Add bot greeting on initialization and disable input after exit command.
Add updated UI screenshot to repo
More wholesome testing for Parser and Todo
Remove .class files
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants