public abstract class AbstractTask extends AbstractPoolable implements Runnable, Schedulable
logger_| Constructor and Description |
|---|
AbstractTask() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
checkInterrupt() |
abstract void |
doWork()
Override this Method in Subclasses to do the "real work".
|
protected TaskExecutor |
getTaskExecutor() |
protected boolean |
isRunnable() |
void |
run()
run method invoked by TaskExecutor.
|
protected void |
schedule(boolean directRunAllowed)
schedule this Task for execution.
|
protected void |
schedule(TaskExecutor executor,
boolean directRunAllowed)
schedule this Task for execution.
|
protected void |
setTaskExecutor(TaskExecutor taskExecutor) |
dispose, reset, setObjectPoolclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitscheduleprotected TaskExecutor getTaskExecutor()
protected void setTaskExecutor(TaskExecutor taskExecutor)
public abstract void doWork()
throws Exception
Exceptionprotected boolean isRunnable()
protected void checkInterrupt()
throws InterruptedException
InterruptedExceptionprotected void schedule(boolean directRunAllowed)
directRunAllowed - true, if the task may be run in the calling thread. false, if the TaskExecutor
should be used.protected void schedule(TaskExecutor executor, boolean directRunAllowed)
executor - TaskExecutor that should execute this TaskdirectRunAllowed - true, if the task may be run in the calling thread. false, if the TaskExecutor
should be used.Copyright © 2015 JacORB. All rights reserved.