Interface AsyncFunction<I,O>
-
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@GwtCompatible public interface AsyncFunction<I,O>
Transforms a value, possibly asynchronously. For an example usage and more information, seeFutures.transformAsync(ListenableFuture, AsyncFunction, Executor)
.- Since:
- 11.0
- Author:
- Chris Povirk
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ListenableFuture<O>
I input)
Returns an outputFuture
to use in place of the giveninput
.
-
-
-
Method Detail
-
apply
I input) throws
Returns an outputFuture
to use in place of the giveninput
. The outputFuture
need not be , makingAsyncFunction
suitable for asynchronous derivations.Throwing an exception from this method is equivalent to returning a failing
Future
.- Throws:
-
-