public static class ProcessUtils.RunCancellationExecuteWatchdog extends org.apache.commons.exec.ExecuteWatchdog implements ProcessUtils.RunCancellationWatchdog.CancelledEventListener
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 |
onCancelled(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 start(Process processToMonitor)
start
in class org.apache.commons.exec.ExecuteWatchdog
public void stop()
stop
in class org.apache.commons.exec.ExecuteWatchdog
public void onCancelled(ProcessUtils.RunCancellationWatchdog.CancelledEvent event)
onCancelled
in interface ProcessUtils.RunCancellationWatchdog.CancelledEventListener
Copyright © 2020–2025 Leibniz Institute for Natural Product Research and Infection Biology - Hans Knöll Institute (HKI). All rights reserved.