public abstract class AbstractCancellableTask extends Thread implements CancellableTask
Thread.State, Thread.UncaughtExceptionHandler
Modifier and Type | Field and Description |
---|---|
protected boolean |
cancellationRequested |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
Modifier | Constructor and Description |
---|---|
protected |
AbstractCancellableTask() |
protected |
AbstractCancellableTask(String threadName) |
Modifier and Type | Method and Description |
---|---|
void |
cancelRequest()
Request to the task that cancel.
|
boolean |
isCancellationRequested()
Return true if has request to cancel to the task.
|
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, run, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
protected AbstractCancellableTask()
protected AbstractCancellableTask(String threadName)
public void cancelRequest()
CancellableTask
cancelRequest
in interface CancellableTask
public boolean isCancellationRequested()
CancellableTask
isCancellationRequested
in interface CancellableTask