Java com.google.common.util.concurrent Futures fields, constructors, methods, implement or subclass

Example usage for Java com.google.common.util.concurrent Futures fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for com.google.common.util.concurrent Futures.

The text is from its open source code.

Method

voidaddCallback(ListenableFuture future, FutureCallback callback)
Registers separate success and failure callbacks to be run when the Future 's computation is java.util.concurrent.Future#isDone() complete or, if the computation is already complete, immediately.
voidaddCallback(final ListenableFuture future, final FutureCallback callback, Executor executor)
Registers separate success and failure callbacks to be run when the Future 's computation is java.util.concurrent.Future#isDone() complete or, if the computation is already complete, immediately.
ListenableFuture>allAsList(ListenableFuture... futures)
Creates a new ListenableFuture whose value is a list containing the values of all its input futures, if all succeed.
ListenableFuture>allAsList( Iterable> futures)
Creates a new ListenableFuture whose value is a list containing the values of all its input futures, if all succeed.
ListenableFuturecatching(ListenableFuture input, Class exceptionType, Function fallback, Executor executor)
Returns a Future whose result is taken from the given primary input or, if the primary input fails with the given exceptionType , from the result provided by the fallback .
ListenableFuturecatching(ListenableFuture input, Class exceptionType, Function fallback)
Returns a Future whose result is taken from the given primary input or, if the primary input fails with the given exceptionType , from the result provided by the fallback .
ListenableFuturecatchingAsync(ListenableFuture input, Class exceptionType, AsyncFunction fallback)
Returns a Future whose result is taken from the given primary input or, if the primary input fails with the given exceptionType , from the result provided by the fallback .
ListenableFuturecatchingAsync(ListenableFuture input, Class exceptionType, AsyncFunction fallback, Executor executor)
Returns a Future whose result is taken from the given primary input or, if the primary input fails with the given exceptionType , from the result provided by the fallback .
ListenableFuturedereference( ListenableFuture> nested)
Returns a new ListenableFuture whose result is the product of calling get() on the Future nested within the given Future , effectively chaining the futures one after the other.
Vget(Future future, long timeout, TimeUnit unit, Class exceptionClass)
Returns the result of Future#get(long,TimeUnit) , converting most exceptions to a new instance of the given checked exception type.
Vget(Future future, Class exceptionClass)
Returns the result of Future#get() , converting most exceptions to a new instance of the given checked exception type.
VgetChecked(Future future, Class exceptionClass, long timeout, TimeUnit unit)
Returns the result of Future#get(long,TimeUnit) , converting most exceptions to a new instance of the given checked exception type.
VgetChecked(Future future, Class exceptionClass)
Returns the result of Future#get() , converting most exceptions to a new instance of the given checked exception type.
VgetUnchecked(Future future)
Returns the result of calling Future#get() uninterruptibly on a task known not to throw a checked exception.
ListenableFutureimmediateCancelledFuture()
Creates a ListenableFuture which is cancelled immediately upon construction, so that isCancelled() always returns true .
CheckedFutureimmediateCheckedFuture(@Nullable V value)
Returns a CheckedFuture which has its value set immediately upon construction.
CheckedFutureimmediateFailedCheckedFuture(X exception)
Returns a CheckedFuture which has an exception set immediately upon construction.
ListenableFutureimmediateFailedFuture(Throwable throwable)
Returns a ListenableFuture which has an exception set immediately upon construction.
ListenableFutureimmediateFuture(@Nullable V value)
Creates a ListenableFuture which has its value set immediately upon construction.
ImmutableList>inCompletionOrder( Iterable> futures)
Returns a list of delegate futures that correspond to the futures received in the order that they complete.
FuturelazyTransform(final Future input, final Function function)
Like #transform(ListenableFuture,Function) except that the transformation function is invoked on each call to Future#get() get() on the returned future.
CheckedFuturemakeChecked(ListenableFuture future, Function mapper)
Creates a CheckedFuture out of a normal ListenableFuture and a Function that maps from Exception instances into the appropriate checked type.
ListenableFuturenonCancellationPropagating(ListenableFuture future)
Creates a new ListenableFuture whose result is set from the supplied future when it completes.
ListenableFuture>successfulAsList(ListenableFuture... futures)
Creates a new ListenableFuture whose value is a list containing the values of all its successful input futures.
ListenableFuture>successfulAsList( Iterable> futures)
Creates a new ListenableFuture whose value is a list containing the values of all its successful input futures.
ListenableFuturetransform(ListenableFuture input, AsyncFunction function)
Returns a new ListenableFuture whose result is asynchronously derived from the result of the given Future .
ListenableFuturetransform(ListenableFuture input, Function function)
Returns a new ListenableFuture whose result is the product of applying the given Function to the result of the given Future .
ListenableFuturetransform(ListenableFuture input, AsyncFunction function, Executor executor)
Returns a new ListenableFuture whose result is asynchronously derived from the result of the given Future .
ListenableFuturetransform(ListenableFuture input, Function function, Executor executor)
Returns a new ListenableFuture whose result is the product of applying the given Function to the result of the given Future .
ListenableFuturetransformAsync(ListenableFuture input, AsyncFunction function, Executor executor)
Returns a new ListenableFuture whose result is asynchronously derived from the result of the given Future .
ListenableFuturetransformAsync(ListenableFuture input, AsyncFunction function)
Returns a new ListenableFuture whose result is asynchronously derived from the result of the given Future .
ListenableFuturewithFallback(ListenableFuture input, FutureFallback fallback)
Returns a Future whose result is taken from the given primary input or, if the primary input fails, from the Future provided by the fallback .
ListenableFuturewithFallback(ListenableFuture input, FutureFallback fallback, Executor executor)
Returns a Future whose result is taken from the given primary input or, if the primary input fails, from the Future provided by the fallback .
ListenableFuturewithTimeout(ListenableFuture delegate, long time, TimeUnit unit, ScheduledExecutorService scheduledExecutor)
Returns a future that delegates to another but will finish early (via a TimeoutException wrapped in an ExecutionException ) if the specified duration expires.