T
- The result object type returned by this future@Deprecated
public class RunnableFutureCallbackAdapter<T>
extends java.lang.Object
implements java.lang.Runnable
FutureCallback
and a Runnable
. Allowing
you to supply this implementation as a Runnable as a listener into a ListenableFuture
and have it convert the future's result into calls into a FutureCallback
.
Instead of constructing this class, it is usually much easier to call into
ListenableFuture.callback(FutureCallback)
.
Constructor and Description |
---|
RunnableFutureCallbackAdapter(java.util.concurrent.Future<T> future,
FutureCallback<? super T> callback)
Deprecated.
Constructs a new
RunnableFutureCallbackAdapter . |
Modifier and Type | Method and Description |
---|---|
void |
run()
Deprecated.
|
public RunnableFutureCallbackAdapter(java.util.concurrent.Future<T> future, FutureCallback<? super T> callback)
RunnableFutureCallbackAdapter
.future
- Future to get result or error fromcallback
- Callback to call into once future has completed