Modifier and Type | Field and Description |
---|---|
private ProcessContext |
context |
private Process[] |
processes |
private AsyncTransferrer[] |
transferrers |
Constructor and Description |
---|
ProcessExecutor(ProcessContext context,
ProcessBuilder[] builders)
The constructor.
|
Modifier and Type | Method and Description |
---|---|
Integer |
call()
This method executes the
Process (es). |
protected void |
dispose()
This method disposes this executor.
|
void |
stop()
This method stops the task.
|
private final ProcessContext context
private final Process[] processes
private final AsyncTransferrer[] transferrers
public ProcessExecutor(ProcessContext context, ProcessBuilder[] builders) throws IOException
context
- is the context of the process pipe.builders
- are the configurations of the Process
(es) to execute. The array needs to have a
length greater than zero.IOException
- if an input/output error occurred.protected void dispose()
destroyed
and all
streams are closed.public void stop()
Stoppable
public Integer call() throws InterruptedException
Process
(es).call
in interface Callable<Integer>
InterruptedException
- if a process was interrupted.Copyright © 2001–2016 mmm-Team. All rights reserved.