public abstract class QTPWorkerThread extends Thread implements AbstractMessageConnector.Joinable
closed
by
its parent, or being forcefully interrupted/stopped by someone else.Thread.State, Thread.UncaughtExceptionHandler
Modifier and Type | Field and Description |
---|---|
protected com.devexperts.logging.Logging |
log |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
Modifier | Constructor and Description |
---|---|
protected |
QTPWorkerThread(String name) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Marks thread as "closed" and interrupts it (if needed).
|
protected abstract void |
doWork() |
protected abstract void |
handleClose(Throwable reason) |
protected abstract void |
handleShutdown() |
boolean |
isClosed()
Returns
true if thread is closed and clears interrupt flag. |
void |
run() |
activeCount, 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, toString, yield
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
join
protected QTPWorkerThread(String name)
public final void close()
public final boolean isClosed() throws InterruptedException
true
if thread is closed and clears interrupt flag.true
if thread is closed and clears interrupt flagInterruptedException
- if thread is interrupted without call to close()
.protected abstract void handleShutdown()
protected abstract void handleClose(Throwable reason)
Copyright © 2002–2025 Devexperts LLC. All rights reserved.