public interface ExecutorSubmitter extends Executor
ExecutorService job submission methods
without exposing the life-cycle management API. Is tweaked to return
promises rather than anemic futures.| Modifier and Type | Method and Description |
|---|---|
<T> Promise<T> |
submit(Callable<T> task)
Submits a value-returning task for execution and returns a Promise
representing the pending results of the task.
|
<T> Promise<T> |
submitSupplier(Supplier<T> task)
Submits a value-returning task for execution and returns a Promise
representing the pending results of the task.
|
<T> Promise<T> submit(Callable<T> task)
T - a T to return.task - the task to submitRejectedExecutionException - if the task cannot be scheduled for
executionNullPointerException - if the task is null<T> Promise<T> submitSupplier(Supplier<T> task)
T - a T to return.task - the task to submitRejectedExecutionException - if the task cannot be scheduled for
executionNullPointerException - if the task is nullCopyright © 2016 Atlassian. All rights reserved.