private class ProcedureExecutor.WorkerThread extends StoppableThread
Thread.State, Thread.UncaughtExceptionHandler| Modifier and Type | Field and Description |
|---|---|
private Procedure<TEnvironment> |
activeProcedure |
private AtomicLong |
executionStartTime |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY| Modifier | Constructor and Description |
|---|---|
|
WorkerThread(ThreadGroup group) |
protected |
WorkerThread(ThreadGroup group,
String prefix) |
| Modifier and Type | Method and Description |
|---|---|
long |
getCurrentRunTime()
Returns the time since the current procedure is running
|
protected boolean |
keepAlive(long lastUpdate) |
void |
run() |
private long |
runProcedure()
Encapsulates execution of the current
activeProcedure for easy tracing. |
void |
sendStopSignal() |
String |
toString() |
awaitTerminationactiveCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, yieldprivate final AtomicLong executionStartTime
private volatile Procedure<TEnvironment> activeProcedure
public WorkerThread(ThreadGroup group)
protected WorkerThread(ThreadGroup group, String prefix)
public void sendStopSignal()
sendStopSignal in class StoppableThreadprivate long runProcedure() throws IOException
activeProcedure for easy tracing.IOExceptionpublic long getCurrentRunTime()
protected boolean keepAlive(long lastUpdate)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.