| Modifier and Type | Class and Description |
|---|---|
| public static interface |
| Modifier and Type | Field and Description |
|---|---|
| private final ThreadLocal | |
| private final WorkerTaskQueue | |
| private final WorkerPool |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | execute(Runnable
the runnable task command)Implements java. Executes the given command at some time in the future. |
| public boolean | |
| public CountDownLatch | Returns: the latch to wait for until the current task can resumeSuspend the current task execution until the task is resumed, the next task in the queue will be executed when there is one. |
| pack-priv WorkerTaskQueue | |
| public static WorkerExecutor |
| inThread | back to summary |
|---|---|
| private final ThreadLocal<Boolean> inThread | |
| orderedTasks | back to summary |
|---|---|
| private final WorkerTaskQueue orderedTasks | |
| workerPool | back to summary |
|---|---|
| private final WorkerPool workerPool | |
| WorkerExecutor | back to summary |
|---|---|
| public WorkerExecutor(WorkerPool workerPool, WorkerTaskQueue orderedTasks) | |
| execute | back to summary |
|---|---|
| public void execute(Runnable command) Implements java. Doc from java. Executes the given command at some time in the future. The command
may execute in a new thread, in a pooled thread, or in the calling
thread, at the discretion of the | |
| inThread | back to summary |
|---|---|
| public boolean inThread() Implements io.
| |
| suspend | back to summary |
|---|---|
| public CountDownLatch suspend(Consumer<WorkerExecutor. Suspend the current task execution until the task is resumed, the next task in the queue will be executed when there is one. The
| |
| taskQueue | back to summary |
|---|---|
| pack-priv WorkerTaskQueue taskQueue() | |
| unwrapWorkerExecutor | back to summary |
|---|---|
| public static WorkerExecutor unwrapWorkerExecutor() | |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public default void |
| resume | back to summary |
|---|---|
| public void resume(Runnable callback) Resume the task, the
| |
| resume | back to summary |
|---|---|
| public default void resume() Like | |