public class NativeExecutableCommand extends ExecutableCommand
ExecutableCommand that provides the
ability to execute a native process. Caution should be taken with this
current implementation as no processing of EOL is provided and results may
vary on different platforms. It is recommended that only automated clients
use this feature due to the many differences in user terminals which may
cause problems with command output not performing as expected.session, stderr, stdin, stdout, STILL_ACTIVE| Constructor and Description |
|---|
NativeExecutableCommand() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
createProcess(String cmd,
Map<String,String> environment)
Create the process but wait for the
ExecutableCommand.onStart() method before
performing any IO. |
int |
getExitCode()
Get the exit code for this process.
|
void |
kill()
Kill the command.
|
void |
onStart()
Called once the command has been started.
|
void |
processStdinData(byte[] data)
Called by the session to pass incoming data into the process.
|
getInputStream, getOutputStream, getSession, getStderrOutputStream, getTimeout, init, startpublic void onStart()
ExecutableCommandonStart in class ExecutableCommandpublic int getExitCode()
ExecutableCommandExecutableCommand.STILL_ACTIVE.getExitCode in class ExecutableCommandpublic boolean createProcess(String cmd, Map<String,String> environment)
ExecutableCommandExecutableCommand.onStart() method before
performing any IO.createProcess in class ExecutableCommandpublic void processStdinData(byte[] data)
throws IOException
ExecutableCommandprocessStdinData in class ExecutableCommandIOExceptionpublic void kill()
ExecutableCommandkill in class ExecutableCommandCopyright © 2025. All rights reserved.