Package org.jboss.as.cli.gui
Class CommandExecutor
- java.lang.Object
-
- org.jboss.as.cli.gui.CommandExecutor
-
public class CommandExecutor extends Object
This class takes a command-line cli command and submits it to the server.- Author:
- Stan Silvert [email protected] (C) 2012 Red Hat Inc.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CommandExecutor.Response
-
Constructor Summary
Constructors Constructor Description CommandExecutor(CliGuiContext cliGuiCtx, Supplier<ModelControllerClient> client)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.jboss.dmr.ModelNode
doCommand(String command)
Submit a command to the server.CommandExecutor.Response
doCommandFullResponse(String command)
User-initiated commands use this method.
-
-
-
Constructor Detail
-
CommandExecutor
public CommandExecutor(CliGuiContext cliGuiCtx, Supplier<ModelControllerClient> client)
-
-
Method Detail
-
doCommand
public org.jboss.dmr.ModelNode doCommand(String command) throws CommandFormatException, IOException
Submit a command to the server.- Parameters:
command
- The CLI command- Returns:
- The DMR response as a ModelNode
- Throws:
CommandFormatException
IOException
-
doCommandFullResponse
public CommandExecutor.Response doCommandFullResponse(String command) throws CommandFormatException, IOException
User-initiated commands use this method.- Parameters:
command
- The CLI command- Returns:
- A Response object containing the command line, DMR request, and DMR response
- Throws:
CommandFormatException
IOException
-
-