| Package | Description |
|---|---|
| org.zeroturnaround.process |
| Modifier and Type | Class and Description |
|---|---|
class |
AbstractProcess
Base implementation of
SystemProcess. |
class |
AndProcess
Represents multiple processes.
|
class |
CompositeProcess
Contains other
SystemProcesses preserving their order. |
class |
Java8Process
Wrapper for
Process since Java 8. |
class |
JavaProcess
Wrapper for
Process. |
class |
OrProcess
Represents a single system process containing alternative
SystemProcess implementations for controlling it. |
class |
PidProcess
Base implementation for processes that use
PID (Process ID) values. |
class |
PollingProcess
Base implementation that polls for a process status.
|
class |
UnixProcess
Process implementation for UNIX PID values.
|
class |
WindowsProcess
Process implementation for Windows PID values.
|
| Modifier and Type | Field and Description |
|---|---|
protected List<? extends SystemProcess> |
CompositeProcess.children |
| Modifier and Type | Method and Description |
|---|---|
SystemProcess |
SystemProcess.destroyForcefully()
Kills this process.
|
SystemProcess |
SystemProcess.destroyGracefully()
Terminates this process.
|
static SystemProcess |
Processes.newProcessForMultiple(SystemProcess... processes)
Combines existing
SystemProcess objects for multiple processes. |
static SystemProcess |
Processes.newProcessWithAlternatives(SystemProcess... processes)
Combines existing
SystemProcess objects as alternative implementations for a single process. |
static SystemProcess |
Processes.newProcessWithAtlernatives(SystemProcess... processes)
Deprecated.
|
static SystemProcess |
Processes.newStandardProcess(Process process)
|
static SystemProcess |
Processes.newStandardProcess(Process process,
int pid)
Creates an instance that represents the given
Process or the given PID. |
| Modifier and Type | Method and Description |
|---|---|
static void |
ProcessUtil.destroyForcefullyAndWait(SystemProcess process)
Destroys the given process forcefully and waits until it finishes or the current thread is interrupted.
|
static void |
ProcessUtil.destroyForcefullyAndWait(SystemProcess process,
long timeout,
TimeUnit unit)
Destroys the given process forcefully and waits until it finishes, a timeout occurs or the current thread is interrupted.
|
static void |
ProcessUtil.destroyGracefullyAndWait(SystemProcess process)
Destroys the given process gracefully and waits until it finishes or the current thread is interrupted.
|
static void |
ProcessUtil.destroyGracefullyAndWait(SystemProcess process,
long timeout,
TimeUnit unit)
Destroys the given process gracefully and waits until it finishes, a timeout occurs or the current thread is interrupted.
|
static void |
ProcessUtil.destroyGracefullyOrForcefullyAndWait(SystemProcess process)
Destroys the given process gracefully and waits until it finishes or the current thread is interrupted.
|
static void |
ProcessUtil.destroyGracefullyOrForcefullyAndWait(SystemProcess process,
long gracefulTimeout,
TimeUnit gracefulTimeoutUnit)
Destroys the given process gracefully and waits until it finishes, a timeout occurs or the current thread is interrupted.
|
static void |
ProcessUtil.destroyGracefullyOrForcefullyAndWait(SystemProcess process,
long gracefulTimeout,
TimeUnit gracefulTimeoutUnit,
long forcefulTimeout,
TimeUnit forcefulTimeoutUnit)
Destroys the given process gracefully and waits until it finishes, first timeout occurs or the current thread is interrupted.
|
protected static void |
CompositeProcess.invokeDestroy(SystemProcess killer,
boolean forceful) |
static SystemProcess |
Processes.newProcessForMultiple(SystemProcess... processes)
Combines existing
SystemProcess objects for multiple processes. |
static SystemProcess |
Processes.newProcessWithAlternatives(SystemProcess... processes)
Combines existing
SystemProcess objects as alternative implementations for a single process. |
static SystemProcess |
Processes.newProcessWithAtlernatives(SystemProcess... processes)
Deprecated.
|
static void |
ProcessUtil.waitFor(SystemProcess process)
Waits until the given process finishes or the current thread is interrupted.
|
static void |
ProcessUtil.waitFor(SystemProcess process,
long timeout,
TimeUnit unit)
Waits until the given process finishes, a timeout is reached or the current thread is interrupted.
|
| Constructor and Description |
|---|
AndProcess(List<? extends SystemProcess> children) |
CompositeProcess(List<? extends SystemProcess> children) |
OrProcess(List<? extends SystemProcess> children) |
Copyright © 2019 ZeroTurnaround. All rights reserved.