All Implemented Interfaces:
Argument

public class ExitCmd extends Subcommand
A subcommand of EngineCmd which simply exits the entire app.

Provides an optional first (second in context of its parent command) TypedArg which accepts a boolean which defaults to false. If true, then no confirmation is made before shut down possibly resulting in data loss.

Aliases: exit, quit, done, bye, close, x

Typical Usage:


     engine quit      - Asks user if they're sure before quitting
     engine close yes - Force closes the app
     engine x         - Asks user if they're sure before quitting
     eng done true    - Force closes the app
     

Author:
Lehlogonolo Poole
See Also:
  • Constructor Details

    • ExitCmd

      public ExitCmd()
  • Method Details

    • run

      public void run(Invoker invoker, SafeJLabel logLabel, String aliasUsed, Object[] args, ArrayList<TaggedArgValue<?>> taggedArgs)
      Description copied from class: Command
      The method to be overridden by subclasses to implement command functionality.
      Overrides:
      run in class Command
      Parameters:
      invoker - The invoker of this command
      logLabel - The JLabel to display log messages.
      aliasUsed - The alias of the command that was used to invoke it.
      args - The arguments passed to the command.
      taggedArgs - Tagged arguments passed to the command.