private static final class AbstractTransformFuture.AsyncTransformFuture<I,O> extends AbstractTransformFuture<I,O,AsyncFunction<? super I,? extends O>,ListenableFuture<? extends O>>
AbstractTransformFuture
that delegates to an AsyncFunction
and
AbstractFuture.setFuture(ListenableFuture)
.AbstractFuture.TrustedFuture<V>
function, inputFuture
Constructor and Description |
---|
AsyncTransformFuture(ListenableFuture<? extends I> inputFuture,
AsyncFunction<? super I,? extends O> function) |
Modifier and Type | Method and Description |
---|---|
(package private) ListenableFuture<? extends O> |
doTransform(AsyncFunction<? super I,? extends O> function,
I input)
Template method for subtypes to actually run the transform.
|
(package private) void |
setResult(ListenableFuture<? extends O> result)
Template method for subtypes to actually set the result.
|
afterDone, create, create, create, create, run
addListener, cancel, get, get, isCancelled, isDone
interruptTask, maybePropagateCancellation, set, setException, setFuture, trustedGetException, wasInterrupted
AsyncTransformFuture(ListenableFuture<? extends I> inputFuture, AsyncFunction<? super I,? extends O> function)
ListenableFuture<? extends O> doTransform(AsyncFunction<? super I,? extends O> function, @Nullable I input) throws java.lang.Exception
AbstractTransformFuture
doTransform
in class AbstractTransformFuture<I,O,AsyncFunction<? super I,? extends O>,ListenableFuture<? extends O>>
java.lang.Exception
void setResult(ListenableFuture<? extends O> result)
AbstractTransformFuture
setResult
in class AbstractTransformFuture<I,O,AsyncFunction<? super I,? extends O>,ListenableFuture<? extends O>>