public static class ProcessUtils.RunCancellationExecuteWatchdog
extends org.apache.commons.exec.ExecuteWatchdog
ExecuteWatchdog
. Adapted to listed to JIPipeProgressInfo
cancellation.Constructor and Description |
---|
RunCancellationExecuteWatchdog(long timeout,
JIPipeProgressInfo progressInfo,
ProcessUtils.ExtendedExecutor extendedExecutor)
Creates a new watchdog with a given timeout.
|
Modifier and Type | Method and Description |
---|---|
void |
onProcessCancelled(ProcessUtils.RunCancellationWatchdog.CancelledEvent event) |
void |
start(Process processToMonitor) |
void |
stop() |
void |
timeoutOccured(org.apache.commons.exec.Watchdog w) |
public RunCancellationExecuteWatchdog(long timeout, JIPipeProgressInfo progressInfo, ProcessUtils.ExtendedExecutor extendedExecutor)
timeout
- the timeout for the process in milliseconds. It must be
greater than 0 or 'INFINITE_TIMEOUT'extendedExecutor
- the executorpublic void timeoutOccured(org.apache.commons.exec.Watchdog w)
timeoutOccured
in interface org.apache.commons.exec.TimeoutObserver
timeoutOccured
in class org.apache.commons.exec.ExecuteWatchdog
public void onProcessCancelled(ProcessUtils.RunCancellationWatchdog.CancelledEvent event)
public void start(Process processToMonitor)
start
in class org.apache.commons.exec.ExecuteWatchdog
public void stop()
stop
in class org.apache.commons.exec.ExecuteWatchdog
Copyright © 2020–2022 Leibniz Institute for Natural Product Research and Infection Biology - Hans Knöll Institute (HKI). All rights reserved.