@@ -0,0 +1,1531 @@
+package seedu.taskboss.logic.commands;%0A%0Aimport seedu.taskboss.commons.exceptions.IllegalValueException;%0Aimport seedu.taskboss.logic.commands.exceptions.CommandException;%0Aimport seedu.taskboss.logic.commands.exceptions.InvalidDatesException;%0Aimport seedu.taskboss.model.task.UniqueTaskList.SortBy;%0A%0A//@@author A0143157J%0A/**%0A * Sort tasks by start date, end date or priority.%0A */%0Apublic class SortCommand extends Command %7B%0A%0A    public static final String COMMAND_WORD = %22sort%22;%0A    public static final String COMMAND_WORD_SHORT = %22s%22;%0A%0A    public static final String MESSAGE_USAGE = COMMAND_WORD + %22/%22 + COMMAND_WORD_SHORT%0A            + %22: Sorts all tasks by either start date, end date or priority. %22%0A            + %22Parameters: SORT_TYPE (sd or ed or p)%5Cn%22%0A            + %22Example: %22 + COMMAND_WORD + %22 sd%5Cn%22%0A            + %22Example: %22 + COMMAND_WORD_SHORT + %22 ed%22;%0A%0A    public static final String MESSAGE_SUCCESS = %22Sorted all tasks.%22;%0A    public static final String ERROR_INVALID_SORT_TYPE = %22Invalid sort type.%22;%0A%0A    private SortBy sortType;%0A%0A    public SortCommand(SortBy sortType) %7B%0A        this.sortType = sortType;%0A    %7D%0A%0A    @Override%0A    public CommandResult execute() throws CommandException, IllegalValueException, InvalidDatesException %7B%0A        assert model != null;%0A        try %7B%0A            model.sortTasks(sortType);%0A            return new CommandResult(String.format(MESSAGE_SUCCESS));%0A        %7D catch (IllegalValueException ive) %7B%0A            throw new CommandException(ERROR_INVALID_SORT_TYPE);%0A        %7D%0A    %7D%0A%0A%7D%0A

Create SortCommand class