Class IdAShell

java.lang.Object
com.io7m.idstore.shell.admin.internal.IdAShell
All Implemented Interfaces:
IdAShellType, AutoCloseable

public final class IdAShell extends Object implements IdAShellType
The basic shell.
  • Constructor Details

    • IdAShell

      public IdAShell(IdAClientSynchronousType inClient, IdAShellOptions inOptions, org.jline.terminal.Terminal inTerminal, PrintWriter inWriter, Map<String,IdAShellCmdType> inCommandsNamed, org.jline.reader.LineReader inReader)
      The basic shell.
      Parameters:
      inClient - The client
      inOptions - The shell options
      inCommandsNamed - The named commands
      inReader - The line reader
      inTerminal - The terminal
      inWriter - The writer
  • Method Details

    • close

      public void close() throws Exception
      Specified by:
      close in interface AutoCloseable
      Throws:
      Exception
    • commands

      public Collection<com.io7m.quarrel.core.QCommandType> commands()
      Specified by:
      commands in interface IdAShellType
      Returns:
      The set of commands exposed by the shell
    • run

      public void run()
      Description copied from interface: IdAShellType
      Run the shell until the user asks it to exit (or it reaches EOF).
      Specified by:
      run in interface IdAShellType
    • exitCode

      public int exitCode()
      Specified by:
      exitCode in interface IdAShellType
      Returns:
      The shell exit code