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

[Brandon Thio] iP #19

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

Conversation

beetee17
Copy link

@beetee17 beetee17 commented Aug 19, 2022

DukePro

“Your mind is for having ideas, not holding them.” – David Allen (source)

DukePro 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);
    }
}

…, simply echos commands entered by the user, and exits when the user types 'bye'
…changes. Load the data from the hard disk when Duke starts up.
… dates in a format such as yyyy-mm-dd format (e.g., 2019-10-15) and print in a different format such as MMM dd yyyy e.g., (Oct 15 2019).
# Conflicts:
#	src/main/java/Deadline.java
#	src/main/java/Task.java
Ui: deals with interactions with the user
Storage: deals with loading tasks from the file and saving tasks in the file
Parser: deals with making sense of the user command
TaskList: contains the task list e.g., it has operations to add/delete tasks in the list
Command classes (i.e., AddCommand, DeleteCommand, ExitCommand etc.) that inherit from an abstract Command class,
# Conflicts:
#	src/main/java/duke/commands/ListTasksCommand.java
Copy link

@jeromepui jeromepui left a comment

Choose a reason for hiding this comment

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

LGTM. 👍 Just some minor fixes to be made.

@@ -0,0 +1,40 @@
package duke.task;
import duke.exceptions.*;

Choose a reason for hiding this comment

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

Imported classes should always be listed explicitly.

Suggested change
import duke.exceptions.*;
import duke.exceptions.ParsingTaskException;

public class Task {
private static final String DATA_PATH = new File("").getAbsolutePath() + "/data/duke.txt";
private String title;
private boolean completed;

Choose a reason for hiding this comment

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

I can tell from your code that the boolean tracks whether the task is completed. Perhaps you should rename it to sound more like a boolean.

Suggested change
private boolean completed;
private boolean isCompleted;

* Deadlines are tasks that need to be done before a specific date/time e.g., submit report by 11/10/2019 5pm
*/
public class Deadline extends Task {
protected LocalDate by;

Choose a reason for hiding this comment

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

by seems vague for a variable name. Perhaps you could rename it to make it clearer.


@Override
public void execute(TaskList taskList, Ui ui, Storage storage) {
List<Task> tasks = taskList.getAll().stream()

Choose a reason for hiding this comment

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

Good use of Java pipelines to find tasks! 👍

Copy link

@adeearyaa adeearyaa left a comment

Choose a reason for hiding this comment

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

Great code!

public class ExitCommand extends Command {
@Override
public void execute(TaskList taskList, Ui ui, Storage storage) {
ui.showGoodByeMessage();

Choose a reason for hiding this comment

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

good descriptive method names

}

@Override
public void execute(TaskList taskList, Ui ui, Storage storage) {

Choose a reason for hiding this comment

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

Great use of streams!

public class InvalidDeadlineException extends InvalidCommandException {
public InvalidDeadlineException() {
super("Could not parse deadline. To create a deadline, "
+ "please use the format in this example: "

Choose a reason for hiding this comment

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

nice exception message


import duke.commands.*;
import duke.enums.Action;
import duke.exceptions.*;

Choose a reason for hiding this comment

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

could have specified which file to import instead of all maybe?

# Conflicts:
#	src/main/java/duke/commands/FindCommand.java
#	src/main/java/duke/commands/ListTasksCommand.java
#	src/main/java/duke/ui/Ui.java
beetee17 and others added 9 commits September 6, 2022 00:02
…ptions that should hold at various points in the code
Replace if-else branching with switch statement for readability
Use assert feature (not JUnit assertions) to document important assumptions
For example, users can now tag a task as "fun" via the command
"tag <index> #fun".

Current limitation is that the feature does not allow users to add
multiple tags at once. For example, it does not allow the command
"tag <index> #urgent, #important, #school".
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.

3 participants