Skip to content

Commit

Permalink
Checkstyle fix (nusCS2113-AY1920S1#58)
Browse files Browse the repository at this point in the history
* Remove instanceof from ReminderCommand

* Updates to ReminderCommand V1.0

* Sorts reminders in ascending order

* Includes Event as part of reminder display

* Merges with upstream

* Changes to Indent Case

* Changes to switch case alignment
  • Loading branch information
muserr authored Oct 2, 2019
1 parent b71c9b2 commit 2a69c16
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 26 deletions.
2 changes: 1 addition & 1 deletion config/checkstyle/checkstyle.xml
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,8 @@
<module name="Indentation">
<property name="basicOffset" value="4"/>
<property name="braceAdjustment" value="0"/>
<property name="caseIndent" value="0"/>
<!-- Modify this to 4 for aesthetic reasons -->
<property name="caseIndent" value="4"/>
<property name="throwsIndent" value="4"/>
<property name="lineWrappingIndentation" value="4"/>
<property name="arrayInitIndent" value="4"/>
Expand Down
48 changes: 24 additions & 24 deletions src/main/java/duchess/logic/parser/Parser.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,30 +31,30 @@ public static Command parse(String input) throws DukeException {
List<String> arguments = words.subList(1, words.size());

switch (keyword) {
case "list":
return new ListCommand();
case "find":
return new FindCommand(arguments);
case "delete":
return new DeleteCommand(arguments);
case "done":
return new DoneCommand(arguments);
case "todo":
return new AddTodoCommand(arguments);
case "deadline":
return new AddDeadlineCommand(arguments);
case "event":
return new AddEventCommand(arguments);
case "reminder":
return new ReminderCommand();
case "snooze":
return new SnoozeCommand(arguments);
case "schedule":
return new ViewScheduleCommand(arguments);
case "bye":
return new ByeCommand();
default:
throw new DukeException("Please enter a valid command.");
case "list":
return new ListCommand();
case "find":
return new FindCommand(arguments);
case "delete":
return new DeleteCommand(arguments);
case "done":
return new DoneCommand(arguments);
case "todo":
return new AddTodoCommand(arguments);
case "deadline":
return new AddDeadlineCommand(arguments);
case "event":
return new AddEventCommand(arguments);
case "reminder":
return new ReminderCommand();
case "snooze":
return new SnoozeCommand(arguments);
case "schedule":
return new ViewScheduleCommand(arguments);
case "bye":
return new ByeCommand();
default:
throw new DukeException("Please enter a valid command.");
}
}
}
1 change: 1 addition & 0 deletions src/main/java/duchess/model/task/Task.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import duchess.model.Module;
import duchess.model.TimeFrame;


import java.util.List;
import java.util.Optional;

Expand Down
1 change: 0 additions & 1 deletion src/main/java/duchess/model/task/Todo.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import duchess.logic.commands.exceptions.DukeException;
import duchess.model.TimeFrame;

import java.util.ArrayList;
import java.util.List;
import java.util.Optional;

Expand Down
Binary file added tasks.dat
Binary file not shown.

0 comments on commit 2a69c16

Please sign in to comment.