public class SyncTask extends Task
| Modifier and Type | Field and Description |
|---|---|
static String |
ADMIN_EXECUTOR
Constant
ADMIN_EXECUTOR="admin" |
static String |
DEFAULT_EXECUTOR
Constant
DEFAULT_EXECUTOR="default" |
| Constructor and Description |
|---|
SyncTask(DefaultTaskCoordinator coordinator,
ContainerTask<?> parent,
Runnable action)
Constructor for SyncTask.
|
SyncTask(DefaultTaskCoordinator coordinator,
ContainerTask<?> parent,
Runnable action,
String preferredExecutor)
Constructor for SyncTask.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
doSubmit()
This method submits a task to be executed and is called when all dependencies are completed for that task
This method should place a runnable on an executor or submit the task in some other way so that it will
run as soon as possible.
|
String |
getPreferredExecutor()
getPreferredExecutor
|
void |
run()
This is the run method where the 'work' related to the Task gets down.
|
void |
setPreferredExecutor(String preferredExecutor)
setPreferredExecutor
|
String |
toString()
toString
|
addDependent, addPrerequisite, completeSubmit, getCoordinator, getMonitor, isFinished, isScheduled, markTaskAsCompleted, postSchedule, preSchedule, schedule, submitRunnable, waitFor, waitForpublic static final String DEFAULT_EXECUTOR
DEFAULT_EXECUTOR="default"public static final String ADMIN_EXECUTOR
ADMIN_EXECUTOR="admin"public SyncTask(DefaultTaskCoordinator coordinator, ContainerTask<?> parent, Runnable action)
Constructor for SyncTask.
coordinator - a DefaultTaskCoordinator object.parent - a ContainerTask object.action - a Runnable object.public SyncTask(DefaultTaskCoordinator coordinator, ContainerTask<?> parent, Runnable action, String preferredExecutor)
Constructor for SyncTask.
coordinator - a DefaultTaskCoordinator object.parent - a ContainerTask object.action - a Runnable object.preferredExecutor - a String object.protected void doSubmit()
public void run()
public String getPreferredExecutor()
getPreferredExecutor
String object.public void setPreferredExecutor(String preferredExecutor)
setPreferredExecutor
preferredExecutor - a String object.Copyright © 2017. All rights reserved.