Class CLICommandContainer

  • All Implemented Interfaces:
    AutoCloseable, org.aesh.command.container.CommandContainer<CLICommandInvocation>

    public class CLICommandContainer
    extends org.aesh.command.container.DefaultCommandContainer<CLICommandInvocation>
    All registered commands are Wrapped into instance of this class in order to print help the CLI way.
    Author:
    jfdenise
    • Method Detail

      • getParser

        public org.aesh.command.impl.parser.CommandLineParser<CLICommandInvocation> getParser()
      • haveBuildError

        public boolean haveBuildError()
      • getBuildErrorMessage

        public String getBuildErrorMessage()
      • printHelp

        public String printHelp​(String childCommandName)
        Specified by:
        printHelp in interface org.aesh.command.container.CommandContainer<CLICommandInvocation>
        Overrides:
        printHelp in class org.aesh.command.container.DefaultCommandContainer<CLICommandInvocation>
      • executeCommand

        public org.aesh.command.container.CommandContainerResult executeCommand​(org.aesh.parser.ParsedLine line,
                                                                                org.aesh.command.invocation.InvocationProviders invocationProviders,
                                                                                org.aesh.readline.AeshContext aeshContext,
                                                                                CLICommandInvocation commandInvocation)
                                                                         throws org.aesh.command.parser.CommandLineParserException,
                                                                                org.aesh.command.validator.OptionValidatorException,
                                                                                org.aesh.command.validator.CommandValidatorException,
                                                                                org.aesh.command.CommandException,
                                                                                InterruptedException
        Specified by:
        executeCommand in interface org.aesh.command.container.CommandContainer<CLICommandInvocation>
        Overrides:
        executeCommand in class org.aesh.command.container.DefaultCommandContainer<CLICommandInvocation>
        Throws:
        org.aesh.command.parser.CommandLineParserException
        org.aesh.command.validator.OptionValidatorException
        org.aesh.command.validator.CommandValidatorException
        org.aesh.command.CommandException
        InterruptedException
      • getWrappedContainer

        public org.aesh.command.container.CommandContainer getWrappedContainer()