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

[Dominic Siew Zhen Yu] iP #494

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

Conversation

Domszy
Copy link

@Domszy Domszy commented Aug 28, 2021

DukeMan

"You will meet many defeats in life, but never let yourself be defeated!" (source: Top 100 most famous quotes)

Manage your tasks with DukeMan, an all-in-one task management application. 🙂

  • Categorise your tasks as deadlines, todo or events
  • FAST SUPER FAST and easy to use
  • Great user interface

All you need to do to use DukeMan 👀

  1. Download DukeMan.
  2. Run the program on an IDE.
  3. Use the todo, deadline and event commands to insert tasks into DukeMan.
  4. Use the "remove" command to remove tasks, and the "done" command to mark the task as complete.
  5. Use "list" to have a look at your tasks.
  6. Use "bye" command to quite DukeMan.

DOWNLOAD NOW!

  • Download DukeMan to enhance your efficiency!
  • What are you waiting for?

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

Copy link

@nataniayp nataniayp left a comment

Choose a reason for hiding this comment

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

overall it's fine! just a bit of naming conventions but otherwise looks good 👍

import java.time.LocalDate;
import java.time.format.DateTimeFormatter;

public class Deadlines extends Task{

Choose a reason for hiding this comment

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

You might want to change the class name to Deadline instead since plural forms are usually for a collection of data such as an array of deadlines. 😄

String command = parser.getCommand();

switch(command) {
case "todo":

Choose a reason for hiding this comment

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

the indentation for case should be the same as switch

*
* @return a string representation of a Event object
*/
public String printName() {

Choose a reason for hiding this comment

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

instead of printName, you might want to override the toString method instead since your method technically does not print the name

import java.io.*;
import java.util.ArrayList;

public class taskList {

Choose a reason for hiding this comment

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

class name should've been capitalised instead -- so TaskList instead of taskList ?

Copy link

@Javiier-pzk Javiier-pzk left a comment

Choose a reason for hiding this comment

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

Hi Dominic! Your code looks good overall but there are just a few naming and coding style issues that you should fix. Cheers!

String todoName = parser.getTaskName();
tasks.addTodo(todoName, true);
break;
case "deadline":

Choose a reason for hiding this comment

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

case statement should have the same indentation level as switch

* @param input the given input by the user
*/

public void parsing(String input) {

Choose a reason for hiding this comment

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

Perhaps a better name for this method will be parse? I think we generally should avoid adding '-ing' behind our methods and class names.

* @author Dominic Siew Zhen Yu
*/

public class DukeMan {

Choose a reason for hiding this comment

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

Perhaps you can name your class name in a way that explains what this class is supposed to do, as per the naming guidelines

import java.time.LocalDate;
import java.time.format.DateTimeFormatter;

public class Deadlines extends Task{

Choose a reason for hiding this comment

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

You may want to change your class name to singular form (deadline) as plural forms are usually for collection of items.

import java.io.*;
import java.util.ArrayList;

public class taskList {

Choose a reason for hiding this comment

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

As part of convention, your class name should have been capitalised. It should be TaskList instead of taskList

boolean isCompleted = (seperate2[0].equals("[✓]"))? true: false;
String eventInfo = seperate2[1];

switch(taskTypeText) {

Choose a reason for hiding this comment

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

Same indentation problem with switch and case


while ((currentLine = reader.readLine()) != null) {
String[] seperate1 = currentLine.toString().split(" ", 2);
String taskTypeText = seperate1[0];

Choose a reason for hiding this comment

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

Perhaps a better name would be taskString ?

//
///**
// * Duke is a chatbot that takes in tasks, which includes todos, deadlines and events, and compiles them
// * in a list. Tasks can be removed from the list and be marked as completed.

Choose a reason for hiding this comment

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

Just a friendly reminder that there should not be large chunks of commented code present as mentioned in the iP grading rubrics. You should delete them if not needed or transfer them somewhere else 😄

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