public final class CommandExecutor extends Object
| Constructor and Description |
|---|
CommandExecutor(File executable)
Creates an instance of this class using the given executable/command.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
callExe()
Deprecated.
This method should not be used anymore, developers should instead provide an empty list to execute().
|
boolean |
execute(List<String> arguments)
Executes an executable/command given some arguments.
|
List<String> |
getError()
Gets the standard error reported by the executable/command.
|
List<String> |
getOutput()
Gets the standard output reported by the command/executable.
|
public CommandExecutor(File executable)
executable - The executable/command to execute.public boolean execute(List<String> arguments) throws InterruptedException
arguments - The arguments to the executable/command.InterruptedException - Thrown if there was an error waiting for the executable/command to finish.@Deprecated public boolean callExe() throws InterruptedException
InterruptedException - Thrown if there was an error waiting for the executable/command to finish.public List<String> getError()
Copyright © 2016. All rights reserved.