Class ByeCommand

java.lang.Object
amadeus.cognition.Command
amadeus.cognition.ByeCommand

public class ByeCommand extends Command
Command to exit the Amadeus application.

This command displays a farewell message and terminates the application.

  • Constructor Details

    • ByeCommand

      public ByeCommand()
  • Method Details

    • execute

      public void execute()
      Displays a farewell message and terminates the application.

      The farewell message is provided by the Speech.sayGoodbye() method.

      Specified by:
      execute in class Command
    • isBye

      public boolean isBye()
      Indicates that this command is a termination command.
      Overrides:
      isBye in class Command
      Returns:
      true to indicate that this command should terminate the application.