Class DeadlineCommand

java.lang.Object
amadeus.cognition.Command
amadeus.cognition.DeadlineCommand

public class DeadlineCommand extends Command
Command to add a new Deadline task to the task list.

This command parses the user input to create a Deadline task and adds it to the list. The input is expected to contain a description and a due date, separated by /by.

  • Constructor Details

    • DeadlineCommand

      public DeadlineCommand(String input) throws AmadeusException
      Constructs a new DeadlineCommand by parsing the user input.

      The input is expected to contain a description and a due date, separated by /by. If the input is empty or in an invalid format, an AmadeusException is thrown.

      Parameters:
      input - the user input containing the task description and due date; must not be null or empty.
      Throws:
      AmadeusException - if the input is empty or in an invalid format.
  • Method Details