Package org.jboss.aesh.console.command.container

Examples of org.jboss.aesh.console.command.container.CommandContainerResult


        public int execute(ConsoleOperation output) throws InterruptedException {
            if (output != null && output.getBuffer().trim().length() > 0) {
                ResultHandler resultHandler = null;
                AeshLine aeshLine = Parser.findAllWords(output.getBuffer());
                try (CommandContainer commandContainer = getCommand( aeshLine, output.getBuffer())) {
                    CommandContainerResult ccResult =
                            commandContainer.executeCommand(aeshLine, invocationProviders, getAeshContext(),
                            commandInvocationServices.getCommandInvocationProvider(
                                    commandInvocationProvider).enhanceCommandInvocation(
                                    new AeshCommandInvocation(console,
                                        output.getControlOperator(),
                                         output.getPid(), this)));

                    result = ccResult.getCommandResult();
                    resultHandler = ccResult.getResultHandler();

                    if(result == CommandResult.SUCCESS && resultHandler != null)
                        resultHandler.onSuccess();
                    else if(resultHandler != null)
                        resultHandler.onFailure(result);
View Full Code Here

TOP

Related Classes of org.jboss.aesh.console.command.container.CommandContainerResult

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.