Index
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form
A
- add(Process) - Method in interface org.zeroturnaround.exec.listener.ProcessDestroyer
-
Returns
trueif the specifiedProcesswas successfully added to the list of processes to be destroy. - add(Process) - Method in class org.zeroturnaround.exec.listener.ShutdownHookProcessDestroyer
-
Returns
trueif the specifiedProcesswas successfully added to the list of processes to destroy upon VM exit. - add(ProcessListener) - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
-
Add new listener.
- addDestroyer(ProcessDestroyer) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Adds a process destroyer to be notified when the process starts and stops.
- addListener(ProcessListener) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Register new process event handler.
- afterFinish(Process, ProcessResult) - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
- afterFinish(Process, ProcessResult) - Method in class org.zeroturnaround.exec.listener.ProcessListener
-
Invoked after a process has finished successfully.
- afterStart(Process, ProcessExecutor) - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
- afterStart(Process, ProcessExecutor) - Method in class org.zeroturnaround.exec.listener.DestroyerListenerAdapter
- afterStart(Process, ProcessExecutor) - Method in class org.zeroturnaround.exec.listener.ProcessListener
-
Invoked after a process has started.
- afterStop(Process) - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
- afterStop(Process) - Method in class org.zeroturnaround.exec.listener.DestroyerListenerAdapter
- afterStop(Process) - Method in class org.zeroturnaround.exec.listener.ProcessListener
-
Invoked after a process has exited (whether finished or cancelled).
- as(Level) - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- asDebug() - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- asError() - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- asInfo() - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- asTrace() - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- asWarn() - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
B
- beforeStart(ProcessExecutor) - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
- beforeStart(ProcessExecutor) - Method in class org.zeroturnaround.exec.listener.ProcessListener
-
Invoked before a process is started.
C
- call() - Method in class org.zeroturnaround.exec.MDCCallableAdapter
- CallerLoggerUtil - Class in org.zeroturnaround.exec.stream
-
Constructs name for the caller logger.
- CallerLoggerUtil() - Constructor for class org.zeroturnaround.exec.stream.CallerLoggerUtil
- checkExitValue(ProcessResult) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Check the exit value of given process result.
- clear() - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
-
Remove all existing listeners.
- clearListeners() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Unregister all existing process event handlers.
- clone() - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
- close() - Method in class org.zeroturnaround.exec.stream.LogOutputStream
-
Writes all remaining data from the buffer.
- close() - Method in class org.zeroturnaround.exec.stream.TeeOutputStream
-
Closes both output streams
- close(Process) - Method in interface org.zeroturnaround.exec.close.ProcessCloser
-
Closes standard streams of a given sub process.
- close(Process) - Method in class org.zeroturnaround.exec.close.StandardProcessCloser
- close(Process) - Method in class org.zeroturnaround.exec.close.TimeoutProcessCloser
- closeTimeout(long, TimeUnit) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets a timeout for closing standard streams of the process being executed.
- command(Iterable) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the program and its arguments which are being executed.
- command(String...) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the program and its arguments which are being executed.
- command(List) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the program and its arguments which are being executed.
- commandSplit(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Splits string by spaces and passes it to
ProcessExecutor.command(String...)
NB: this method do not handle whitespace escaping,"mkdir new\ folder"would be interpreted as{"mkdir", "new\", "folder"}command. - CompositeProcessListener - Class in org.zeroturnaround.exec.listener
-
Composite process event handler.
- CompositeProcessListener() - Constructor for class org.zeroturnaround.exec.listener.CompositeProcessListener
- CompositeProcessListener(List) - Constructor for class org.zeroturnaround.exec.listener.CompositeProcessListener
- createProcessErrorPump(InputStream, OutputStream) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Create the pump to handle error output.
- createProcessOutputPump(InputStream, OutputStream) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Create the pump to handle process output.
- createPump(InputStream, OutputStream) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Creates a stream pumper to copy the given input stream to the given output stream.
- createPump(InputStream, OutputStream, boolean) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Creates a stream pumper to copy the given input stream to the given output stream.
- createPump(InputStream, OutputStream, boolean, boolean) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Creates a stream pumper to copy the given input stream to the given output stream.
- createSystemInPump(InputStream, OutputStream) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Creates a stream pumper to copy the given input stream to the given output stream.
D
- debug() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- debug(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- debug(Logger) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- DEBUG - Enum constant in enum org.zeroturnaround.exec.stream.slf4j.Level
- DEBUG - Static variable in class org.zeroturnaround.exec.MessageLoggers
- DEFAULT_EXIT_VALUES - Static variable in class org.zeroturnaround.exec.ProcessExecutor
- DEFAULT_REDIRECT_ERROR_STREAM - Static variable in class org.zeroturnaround.exec.ProcessExecutor
- destroyer(ProcessDestroyer) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the process destroyer to be notified when the process starts and stops.
- DestroyerListenerAdapter - Class in org.zeroturnaround.exec.listener
-
Process event handler that wraps a process destroyer.
- DestroyerListenerAdapter(ProcessDestroyer) - Constructor for class org.zeroturnaround.exec.listener.DestroyerListenerAdapter
- destroyOnExit() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the started process to be destroyed on VM exit (shutdown hooks are executed).
- DestroyProcessStopper - Class in org.zeroturnaround.exec.stop
-
Default
ProcessStopperimplementation that just invokesProcess.destroy(). - DestroyProcessStopper() - Constructor for class org.zeroturnaround.exec.stop.DestroyProcessStopper
- directory(File) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets this working directory for the process being executed.
- doClose(Process) - Method in class org.zeroturnaround.exec.close.TimeoutProcessCloser
E
- environment(String, String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Adds a single additional environment variable for the process being executed.
- environment(Map) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Adds additional environment variables for the process being executed.
- err - Variable in class org.zeroturnaround.exec.stream.PumpStreamHandler
- ERROR - Enum constant in enum org.zeroturnaround.exec.stream.slf4j.Level
- errorThread - Variable in class org.zeroturnaround.exec.stream.PumpStreamHandler
- execute() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Executes the sub process.
- executeNoTimeout() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Executes the sub process.
- ExecuteStreamHandler - Interface in org.zeroturnaround.exec.stream
-
Used by
Executeto handle input and output stream of subprocesses. - exitValue() - Method in exception class org.zeroturnaround.exec.InvalidResultException
-
Deprecated.
- exitValue() - Method in class org.zeroturnaround.exec.ProcessResult
-
Deprecated.
- exitValue(Integer) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the allowed exit value for the process being executed.
- exitValueAny() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Allows any exit value for the process being executed.
- exitValueNormal() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Allows only
0as the exit value for the process being executed. - exitValues(int[]) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the allowed exit values for the process being executed.
- exitValues(Integer...) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the allowed exit values for the process being executed.
F
- flush() - Method in class org.zeroturnaround.exec.stream.LogOutputStream
-
Flush this log stream.
- flush() - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
- flush() - Method in class org.zeroturnaround.exec.stream.TeeOutputStream
-
Flush both output streams.
- future() - Method in class org.zeroturnaround.exec.StartedProcess
-
Deprecated.use
StartedProcess.getFuture()instead.
G
- get(Level) - Static method in class org.zeroturnaround.exec.MessageLoggers
- getBytes() - Method in class org.zeroturnaround.exec.ProcessOutput
- getCommand() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Returns this process executor's operating system program and arguments.
- getDirectory() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Returns this process executor's working directory.
- getEnvironment() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Returns this process executor's additional environment variables.
- getErr() - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Get the error stream.
- getErrorCode() - Method in exception class org.zeroturnaround.exec.ProcessInitException
- getExitValue() - Method in exception class org.zeroturnaround.exec.InvalidResultException
- getExitValue() - Method in class org.zeroturnaround.exec.ProcessResult
- getFuture() - Method in class org.zeroturnaround.exec.StartedProcess
- getInput() - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Get the input stream.
- getLines() - Method in class org.zeroturnaround.exec.ProcessOutput
- getLines(String) - Method in class org.zeroturnaround.exec.ProcessOutput
- getLinesAsUTF8() - Method in class org.zeroturnaround.exec.ProcessOutput
- getLogger() - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jOutputStream
- getName(String) - Static method in class org.zeroturnaround.exec.stream.CallerLoggerUtil
-
Returns full name for the caller class' logger.
- getName(String, int) - Static method in class org.zeroturnaround.exec.stream.CallerLoggerUtil
-
Returns full name for the caller class' logger.
- getOut() - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Get the output stream.
- getOutput() - Method in class org.zeroturnaround.exec.ProcessResult
- getProcess() - Method in class org.zeroturnaround.exec.StartedProcess
- getResult() - Method in exception class org.zeroturnaround.exec.InvalidResultException
- getString() - Method in class org.zeroturnaround.exec.ProcessOutput
- getString(String) - Method in class org.zeroturnaround.exec.ProcessOutput
- getUTF8() - Method in class org.zeroturnaround.exec.ProcessOutput
H
- hasOutput() - Method in class org.zeroturnaround.exec.ProcessResult
I
- info() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- info(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- info(Logger) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- INFO - Enum constant in enum org.zeroturnaround.exec.stream.slf4j.Level
- INFO - Static variable in class org.zeroturnaround.exec.MessageLoggers
- input - Variable in class org.zeroturnaround.exec.stream.PumpStreamHandler
- inputStreamPumper - Variable in class org.zeroturnaround.exec.stream.PumpStreamHandler
- InputStreamPumper - Class in org.zeroturnaround.exec.stream
-
Copies all data from an System.input stream to an output stream of the executed process.
- InputStreamPumper(InputStream, OutputStream) - Constructor for class org.zeroturnaround.exec.stream.InputStreamPumper
-
Create a new stream pumper.
- inputThread - Variable in class org.zeroturnaround.exec.stream.PumpStreamHandler
- INSTANCE - Static variable in class org.zeroturnaround.exec.listener.ShutdownHookProcessDestroyer
-
Singleton instance of the
ShutdownHookProcessDestroyer. - INSTANCE - Static variable in class org.zeroturnaround.exec.stop.DestroyProcessStopper
-
Singleton instance of the
DestroyProcessStopper. - INSTANCE - Static variable in class org.zeroturnaround.exec.stop.NopProcessStopper
-
Singleton instance of the
NopProcessStopper. - InvalidExitValueException - Exception Class in org.zeroturnaround.exec
-
Process finished with a forbidden exit value.
- InvalidExitValueException(String, ProcessResult) - Constructor for exception class org.zeroturnaround.exec.InvalidExitValueException
- InvalidOutputException - Exception Class in org.zeroturnaround.exec
-
Process finished with an unexpected output.
- InvalidOutputException(String, ProcessResult) - Constructor for exception class org.zeroturnaround.exec.InvalidOutputException
- InvalidResultException - Exception Class in org.zeroturnaround.exec
-
Process finished with an unexpected result.
- InvalidResultException(String, ProcessResult) - Constructor for exception class org.zeroturnaround.exec.InvalidResultException
- invokeSubmit(ExecutorService, Callable) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Override this to customize how the waiting task is started in the background.
- isAddedAsShutdownHook() - Method in class org.zeroturnaround.exec.listener.ShutdownHookProcessDestroyer
-
Returns whether or not the ProcessDestroyer is registered as as shutdown hook
- isFinished() - Method in class org.zeroturnaround.exec.stream.StreamPumper
-
Tells whether the end of the stream has been reached.
L
- Level - Enum in org.zeroturnaround.exec.stream.slf4j
-
Slf4j logging level.
- listener(ProcessListener) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Unregister all existing process event handlers and register new one.
- log - Variable in class org.zeroturnaround.exec.stream.slf4j.Slf4jOutputStream
- LogOutputStream - Class in org.zeroturnaround.exec.stream
-
Base class to connect a logging system to the output and/or error stream of then external process.
- LogOutputStream() - Constructor for class org.zeroturnaround.exec.stream.LogOutputStream
M
- MDCCallableAdapter<T> - Class in org.zeroturnaround.exec
-
Restores the MDC context map for the target action.
- MDCCallableAdapter(Callable, Map) - Constructor for class org.zeroturnaround.exec.MDCCallableAdapter
- MDCRunnableAdapter - Class in org.zeroturnaround.exec
-
Restores the MDC context map for the target action.
- MDCRunnableAdapter(Runnable, Map) - Constructor for class org.zeroturnaround.exec.MDCRunnableAdapter
- message(Logger, String, Object...) - Method in interface org.zeroturnaround.exec.MessageLogger
-
Log a message at certain level according to the specified format and arguments.
- MessageLogger - Interface in org.zeroturnaround.exec
-
Logs messages at certain level.
- MessageLoggers - Class in org.zeroturnaround.exec
-
Contains
MessageLoggerinstances for various log levels.
N
- newExecutor(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
- newInstance(String, IOException) - Static method in exception class org.zeroturnaround.exec.ProcessInitException
-
Try to wrap a given
IOExceptioninto aProcessInitException. - newThread(Runnable) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Override this to customize how the background task is created.
- NOP - Static variable in class org.zeroturnaround.exec.MessageLoggers
- NopProcessStopper - Class in org.zeroturnaround.exec.stop
-
ProcessStopperimplementation that does nothing - it keeps the process running. - NopProcessStopper() - Constructor for class org.zeroturnaround.exec.stop.NopProcessStopper
- NULL_OUTPUT_STREAM - Static variable in class org.zeroturnaround.exec.stream.NullOutputStream
-
A singleton.
- NullOutputStream - Class in org.zeroturnaround.exec.stream
-
An OutputStream which ignores everything written to it.
- NullOutputStream() - Constructor for class org.zeroturnaround.exec.stream.NullOutputStream
O
- of(Class) - Static method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- of(Class, String) - Static method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
-
Constructs a logger from a class name and an additional name, appended to the end.
- of(String) - Static method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- of(Logger) - Static method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- ofCaller() - Static method in class org.zeroturnaround.exec.stream.slf4j.Slf4jStream
- org.zeroturnaround.exec - package org.zeroturnaround.exec
- org.zeroturnaround.exec.close - package org.zeroturnaround.exec.close
- org.zeroturnaround.exec.listener - package org.zeroturnaround.exec.listener
- org.zeroturnaround.exec.stop - package org.zeroturnaround.exec.stop
- org.zeroturnaround.exec.stream - package org.zeroturnaround.exec.stream
- org.zeroturnaround.exec.stream.slf4j - package org.zeroturnaround.exec.stream.slf4j
- out - Variable in class org.zeroturnaround.exec.stream.PumpStreamHandler
- output() - Method in class org.zeroturnaround.exec.ProcessResult
- outputString() - Method in class org.zeroturnaround.exec.ProcessResult
- outputString(String) - Method in class org.zeroturnaround.exec.ProcessResult
- outputThread - Variable in class org.zeroturnaround.exec.stream.PumpStreamHandler
- outputUTF8() - Method in class org.zeroturnaround.exec.ProcessResult
P
- process() - Method in class org.zeroturnaround.exec.StartedProcess
-
Deprecated.use
StartedProcess.getProcess()instead. - processBuffer() - Method in class org.zeroturnaround.exec.stream.LogOutputStream
-
Converts the buffer to a string and sends it to
processLine. - ProcessCloser - Interface in org.zeroturnaround.exec.close
-
Abstraction for closing sub process' streams.
- ProcessDestroyer - Interface in org.zeroturnaround.exec.listener
-
Destroys all registered
Processafter a certain event, typically when the VM exits - ProcessExecutor - Class in org.zeroturnaround.exec
-
Helper for executing sub processes.
- ProcessExecutor() - Constructor for class org.zeroturnaround.exec.ProcessExecutor
-
Creates new
ProcessExecutorinstance. - ProcessExecutor(Iterable) - Constructor for class org.zeroturnaround.exec.ProcessExecutor
-
Creates new
ProcessExecutorinstance for the given program and its arguments. - ProcessExecutor(String...) - Constructor for class org.zeroturnaround.exec.ProcessExecutor
-
Creates new
ProcessExecutorinstance for the given program and its arguments. - ProcessExecutor(List) - Constructor for class org.zeroturnaround.exec.ProcessExecutor
-
Creates new
ProcessExecutorinstance for the given program and its arguments. - ProcessInitException - Exception Class in org.zeroturnaround.exec
-
Creating a process failed providing an error code.
- ProcessInitException(String, Throwable, int) - Constructor for exception class org.zeroturnaround.exec.ProcessInitException
- processLine(String) - Method in class org.zeroturnaround.exec.stream.LogOutputStream
-
Logs a line to the log system of the user.
- processLine(String) - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jDebugOutputStream
- processLine(String) - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jErrorOutputStream
- processLine(String) - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jInfoOutputStream
- processLine(String) - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jTraceOutputStream
- processLine(String) - Method in class org.zeroturnaround.exec.stream.slf4j.Slf4jWarnOutputStream
- ProcessListener - Class in org.zeroturnaround.exec.listener
-
Event handler for process events.
- ProcessListener() - Constructor for class org.zeroturnaround.exec.listener.ProcessListener
- ProcessOutput - Class in org.zeroturnaround.exec
-
Standard output of a finished process.
- ProcessOutput(byte[]) - Constructor for class org.zeroturnaround.exec.ProcessOutput
- ProcessResult - Class in org.zeroturnaround.exec
-
Exit value and output of a finished process.
- ProcessResult(int, ProcessOutput) - Constructor for class org.zeroturnaround.exec.ProcessResult
- ProcessStopper - Interface in org.zeroturnaround.exec.stop
-
Abstraction for stopping sub processes.
- pumps() - Method in class org.zeroturnaround.exec.ProcessExecutor
- PumpStreamHandler - Class in org.zeroturnaround.exec.stream
-
Copies standard output and error of subprocesses to standard output and error of the parent process.
- PumpStreamHandler() - Constructor for class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Construct a new
PumpStreamHandler. - PumpStreamHandler(OutputStream) - Constructor for class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Construct a new
PumpStreamHandler. - PumpStreamHandler(OutputStream, OutputStream) - Constructor for class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Construct a new
PumpStreamHandler. - PumpStreamHandler(OutputStream, OutputStream, InputStream) - Constructor for class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Construct a new
PumpStreamHandler.
R
- readOutput(boolean) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets this process executor's
readOutputproperty. - redirectError(OutputStream) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Redirects the process' error stream to given output stream.
- redirectErrorAlsoTo(OutputStream) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Redirects the process' error stream also to a given output stream.
- redirectErrorAsDebug() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectErrorAsDebug(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectErrorAsDebug(Logger) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectErrorAsInfo() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectErrorAsInfo(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectErrorAsInfo(Logger) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectErrorStream(boolean) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets this process executor's
redirectErrorStreamproperty. - redirectInput(InputStream) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the input stream to redirect to the process' input stream.
- redirectOutput(OutputStream) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Redirects the process' output stream to given output stream.
- redirectOutputAlsoTo(OutputStream) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Redirects the process' output stream also to a given output stream.
- redirectOutputAsDebug() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectOutputAsDebug(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectOutputAsDebug(Logger) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectOutputAsInfo() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectOutputAsInfo(String) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- redirectOutputAsInfo(Logger) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Deprecated.
- remove(Process) - Method in interface org.zeroturnaround.exec.listener.ProcessDestroyer
-
Returns
trueif the specifiedProcesswas successfully removed from the list of processes to be destroy. - remove(Process) - Method in class org.zeroturnaround.exec.listener.ShutdownHookProcessDestroyer
-
Returns
trueif the specifiedProcesswas successfully removed from the list of processes to destroy upon VM exit. - remove(ProcessListener) - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
-
Remove existing listener.
- removeAll(Class) - Method in class org.zeroturnaround.exec.listener.CompositeProcessListener
-
Remove existing listeners of given type or its sub-types.
- removeListener(ProcessListener) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Unregister existing process event handler.
- removeListeners(Class) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Unregister existing process event handlers of given type or its sub-types.
- result() - Method in exception class org.zeroturnaround.exec.InvalidResultException
-
Deprecated.
- run() - Method in class org.zeroturnaround.exec.listener.ShutdownHookProcessDestroyer
-
Invoked by the VM when it is exiting.
- run() - Method in class org.zeroturnaround.exec.MDCRunnableAdapter
- run() - Method in class org.zeroturnaround.exec.stream.InputStreamPumper
-
Copies data from the input stream to the output stream.
- run() - Method in class org.zeroturnaround.exec.stream.StreamPumper
-
Copies data from the input stream to the output stream.
S
- setMessageLogger(MessageLogger) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Changes how most common messages about starting and waiting for processes are actually logged.
- setProcessErrorStream(InputStream) - Method in interface org.zeroturnaround.exec.stream.ExecuteStreamHandler
-
Install a handler for the error stream of the subprocess.
- setProcessErrorStream(InputStream) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Set the
InputStreamfrom which to read the standard error of the process. - setProcessInputStream(OutputStream) - Method in interface org.zeroturnaround.exec.stream.ExecuteStreamHandler
-
Install a handler for the input stream of the subprocess.
- setProcessInputStream(OutputStream) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Set the
OutputStreamby means of which input can be sent to the process. - setProcessOutputStream(InputStream) - Method in interface org.zeroturnaround.exec.stream.ExecuteStreamHandler
-
Install a handler for the output stream of the subprocess.
- setProcessOutputStream(InputStream) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Set the
InputStreamfrom which to read the standard output of the process. - ShutdownHookProcessDestroyer - Class in org.zeroturnaround.exec.listener
-
Destroys all registered
Processes when the VM exits. - ShutdownHookProcessDestroyer() - Constructor for class org.zeroturnaround.exec.listener.ShutdownHookProcessDestroyer
-
Constructs a
ProcessDestroyerand obtainsRuntime.addShutdownHook()andRuntime.removeShutdownHook()through reflection. - size() - Method in interface org.zeroturnaround.exec.listener.ProcessDestroyer
-
Returns the number of registered processes.
- size() - Method in class org.zeroturnaround.exec.listener.ShutdownHookProcessDestroyer
-
Returns the number of registered processes.
- SLEEPING_TIME - Static variable in class org.zeroturnaround.exec.stream.InputStreamPumper
- Slf4jDebugOutputStream - Class in org.zeroturnaround.exec.stream.slf4j
-
Output stream that writes
debuglevel messages to a givenLogger. - Slf4jDebugOutputStream(Logger) - Constructor for class org.zeroturnaround.exec.stream.slf4j.Slf4jDebugOutputStream
- Slf4jErrorOutputStream - Class in org.zeroturnaround.exec.stream.slf4j
-
Output stream that writes
errorlevel messages to a givenLogger. - Slf4jErrorOutputStream(Logger) - Constructor for class org.zeroturnaround.exec.stream.slf4j.Slf4jErrorOutputStream
- Slf4jInfoOutputStream - Class in org.zeroturnaround.exec.stream.slf4j
-
Output stream that writes
infolevel messages to a givenLogger. - Slf4jInfoOutputStream(Logger) - Constructor for class org.zeroturnaround.exec.stream.slf4j.Slf4jInfoOutputStream
- Slf4jOutputStream - Class in org.zeroturnaround.exec.stream.slf4j
-
Output stream that writes to a given
Logger. - Slf4jOutputStream(Logger) - Constructor for class org.zeroturnaround.exec.stream.slf4j.Slf4jOutputStream
- Slf4jStream - Class in org.zeroturnaround.exec.stream.slf4j
-
Creates output streams that write to
Loggers. - Slf4jTraceOutputStream - Class in org.zeroturnaround.exec.stream.slf4j
-
Output stream that writes
tracelevel messages to a givenLogger. - Slf4jTraceOutputStream(Logger) - Constructor for class org.zeroturnaround.exec.stream.slf4j.Slf4jTraceOutputStream
- Slf4jWarnOutputStream - Class in org.zeroturnaround.exec.stream.slf4j
-
Output stream that writes
warnlevel messages to a givenLogger. - Slf4jWarnOutputStream(Logger) - Constructor for class org.zeroturnaround.exec.stream.slf4j.Slf4jWarnOutputStream
- StandardProcessCloser - Class in org.zeroturnaround.exec.close
-
Stops
ExecuteStreamHandlerfrom pumping the streams and closes them. - StandardProcessCloser(ExecuteStreamHandler) - Constructor for class org.zeroturnaround.exec.close.StandardProcessCloser
- start() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Start the sub process.
- start() - Method in interface org.zeroturnaround.exec.stream.ExecuteStreamHandler
-
Start handling of the streams.
- start() - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Start the
Threads. - StartedProcess - Class in org.zeroturnaround.exec
-
Represents a process that has started.
- StartedProcess(Process, Future) - Constructor for class org.zeroturnaround.exec.StartedProcess
- startInternal() - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Start the process and its stream handlers.
- stop() - Method in interface org.zeroturnaround.exec.stream.ExecuteStreamHandler
-
Stop handling of the streams - will not be restarted.
- stop() - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Stop pumping the streams.
- stop(Process) - Method in class org.zeroturnaround.exec.stop.DestroyProcessStopper
- stop(Process) - Method in class org.zeroturnaround.exec.stop.NopProcessStopper
- stop(Process) - Method in interface org.zeroturnaround.exec.stop.ProcessStopper
-
Stops a given sub process.
- stopper(ProcessStopper) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets the helper for stopping the process in case of timeout or cancellation.
- stopProcessing() - Method in class org.zeroturnaround.exec.stream.InputStreamPumper
- StreamPumper - Class in org.zeroturnaround.exec.stream
-
Copies all data from an input stream to an output stream.
- StreamPumper(InputStream, OutputStream) - Constructor for class org.zeroturnaround.exec.stream.StreamPumper
-
Create a new stream pumper.
- StreamPumper(InputStream, OutputStream, boolean) - Constructor for class org.zeroturnaround.exec.stream.StreamPumper
-
Create a new stream pumper.
- StreamPumper(InputStream, OutputStream, boolean, boolean) - Constructor for class org.zeroturnaround.exec.stream.StreamPumper
-
Create a new stream pumper.
- StreamPumper(InputStream, OutputStream, boolean, int) - Constructor for class org.zeroturnaround.exec.stream.StreamPumper
-
Create a new stream pumper.
- StreamPumper(InputStream, OutputStream, boolean, int, boolean) - Constructor for class org.zeroturnaround.exec.stream.StreamPumper
-
Create a new stream pumper.
- streams - Variable in class org.zeroturnaround.exec.close.StandardProcessCloser
- streams() - Method in class org.zeroturnaround.exec.ProcessExecutor
- streams(ExecuteStreamHandler) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets a stream handler for the process being executed.
T
- TeeOutputStream - Class in org.zeroturnaround.exec.stream
-
Splits an OutputStream into two.
- TeeOutputStream(OutputStream, OutputStream) - Constructor for class org.zeroturnaround.exec.stream.TeeOutputStream
- timeout(long, TimeUnit) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Sets a timeout for the process being executed.
- TimeoutProcessCloser - Class in org.zeroturnaround.exec.close
-
Same as
StandardProcessCloserbut only waits fixed period for the closing. - TimeoutProcessCloser(ExecuteStreamHandler, long, TimeUnit) - Constructor for class org.zeroturnaround.exec.close.TimeoutProcessCloser
-
Creates new instance of
TimeoutProcessCloser. - TRACE - Enum constant in enum org.zeroturnaround.exec.stream.slf4j.Level
- TRACE - Static variable in class org.zeroturnaround.exec.MessageLoggers
V
- valueOf(String) - Static method in enum org.zeroturnaround.exec.stream.slf4j.Level
-
Returns the enum constant of this type with the specified name.
- values() - Static method in enum org.zeroturnaround.exec.stream.slf4j.Level
-
Returns an array containing the constants of this enum type, in the order they are declared.
W
- waitFor() - Method in class org.zeroturnaround.exec.stream.StreamPumper
-
This method blocks until the stream pumper finishes.
- WARN - Enum constant in enum org.zeroturnaround.exec.stream.slf4j.Level
- wrapTask(Runnable) - Method in class org.zeroturnaround.exec.stream.PumpStreamHandler
-
Override this to customize how the background task is created.
- wrapTask(Callable) - Method in class org.zeroturnaround.exec.ProcessExecutor
-
Override this to customize how the background task is created.
- write(byte[]) - Method in class org.zeroturnaround.exec.stream.NullOutputStream
- write(byte[]) - Method in class org.zeroturnaround.exec.stream.TeeOutputStream
-
Write a byte array to both output streams.
- write(byte[], int, int) - Method in class org.zeroturnaround.exec.stream.LogOutputStream
-
Write a block of characters to the output stream
- write(byte[], int, int) - Method in class org.zeroturnaround.exec.stream.NullOutputStream
- write(byte[], int, int) - Method in class org.zeroturnaround.exec.stream.TeeOutputStream
-
Write a byte array to both output streams.
- write(int) - Method in class org.zeroturnaround.exec.stream.LogOutputStream
-
Write the data to the buffer and flush the buffer, if a line separator is detected.
- write(int) - Method in class org.zeroturnaround.exec.stream.NullOutputStream
- write(int) - Method in class org.zeroturnaround.exec.stream.TeeOutputStream
-
Write a byte to both output streams.
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form
ProcessExecutor.redirectOutput(OutputStream)andSlf4jStream