V - The type of the result of the Future.public interface ListenableFuture<V> extends Future<V>
Future interface inspired by the Google Guava's
ListenableFuture.| Modifier and Type | Method and Description |
|---|---|
void |
addListener(Runnable runnable,
Executor executor)
Add a
Runnable to be executed once the future is completed via
the provided executable. |
void addListener(Runnable runnable, Executor executor) throws RejectedExecutionException, IllegalArgumentException
Runnable to be executed once the future is completed via
the provided executable.
The order that Runnables are executed is unspecified.
runnable - The myRunnable to execute.executor - Executor to use with the myRunnable.RejectedExecutionException - If the future is already complete and the executor rejects
the request.IllegalArgumentException - On the myRunnable or executor being null.Copyright © 2011–2014 Allanbank Consulting, Inc.. All rights reserved.