Uses of Class
com.google.common.util.concurrent.ClosingFuture
-
Uses of ClosingFuture in com.google.common.util.concurrent
Modifier and TypeFieldDescriptionprotected final ImmutableList
<ClosingFuture<?>> ClosingFuture.Combiner.inputs
Modifier and TypeMethodDescriptionClosingFuture.AsyncClosingFunction.apply
(ClosingFuture.DeferredCloser closer, T input) Applies this function to an input, or throws an exception if unable to do so.ClosingFuture.Combiner2.AsyncClosingFunction2.apply
(ClosingFuture.DeferredCloser closer, V1 value1, V2 value2) Applies this function to two inputs, or throws an exception if unable to do so.ClosingFuture.Combiner3.AsyncClosingFunction3.apply
(ClosingFuture.DeferredCloser closer, V1 value1, V2 value2, V3 value3) Applies this function to three inputs, or throws an exception if unable to do so.ClosingFuture.Combiner4.AsyncClosingFunction4.apply
(ClosingFuture.DeferredCloser closer, V1 value1, V2 value2, V3 value3, V4 value4) Applies this function to four inputs, or throws an exception if unable to do so.ClosingFuture.Combiner5.AsyncClosingFunction5.apply
(ClosingFuture.DeferredCloser closer, V1 value1, V2 value2, V3 value3, V4 value4, V5 value5) Applies this function to five inputs, or throws an exception if unable to do so.ClosingFuture.AsyncClosingCallable.call
(ClosingFuture.DeferredCloser closer) Computes a result, or throws an exception if unable to do so.ClosingFuture.Combiner.AsyncCombiningCallable.call
(ClosingFuture.DeferredCloser closer, ClosingFuture.Peeker peeker) Computes aClosingFuture
result, or throws an exception if unable to do so.<V extends @Nullable Object>
ClosingFuture<V> ClosingFuture.Combiner.call
(ClosingFuture.Combiner.CombiningCallable<V> combiningCallable, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying a combining function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner2.call
(ClosingFuture.Combiner2.ClosingFunction2<V1, V2, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying a combining function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner3.call
(ClosingFuture.Combiner3.ClosingFunction3<V1, V2, V3, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying a combining function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner4.call
(ClosingFuture.Combiner4.ClosingFunction4<V1, V2, V3, V4, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying a combining function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner5.call
(ClosingFuture.Combiner5.ClosingFunction5<V1, V2, V3, V4, V5, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying a combining function to their values.<V extends @Nullable Object>
ClosingFuture<V> ClosingFuture.Combiner.callAsync
(ClosingFuture.Combiner.AsyncCombiningCallable<V> combiningCallable, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying aClosingFuture
-returning function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner2.callAsync
(ClosingFuture.Combiner2.AsyncClosingFunction2<V1, V2, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying aClosingFuture
-returning function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner3.callAsync
(ClosingFuture.Combiner3.AsyncClosingFunction3<V1, V2, V3, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying aClosingFuture
-returning function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner4.callAsync
(ClosingFuture.Combiner4.AsyncClosingFunction4<V1, V2, V3, V4, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying aClosingFuture
-returning function to their values.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.Combiner5.callAsync
(ClosingFuture.Combiner5.AsyncClosingFunction5<V1, V2, V3, V4, V5, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from the inputs by applying aClosingFuture
-returning function to their values.<X extends Throwable>
ClosingFuture<V> ClosingFuture.catching
(Class<X> exceptionType, ClosingFuture.ClosingFunction<? super X, ? extends V> fallback, Executor executor) Returns a newClosingFuture
pipeline step derived from this one by applying a function to its exception if it is an instance of a given exception type.<X extends Throwable>
ClosingFuture<V> ClosingFuture.catchingAsync
(Class<X> exceptionType, ClosingFuture.AsyncClosingFunction<? super X, ? extends V> fallback, Executor executor) Returns a newClosingFuture
pipeline step derived from this one by applying a function that returns aClosingFuture
to its exception if it is an instance of a given exception type.static <C extends @Nullable Object & @Nullable AutoCloseable>
ClosingFuture<C> ClosingFuture.eventuallyClosing
(ListenableFuture<C> future, Executor closingExecutor) Deprecated.static <V extends @Nullable Object>
ClosingFuture<V> ClosingFuture.from
(ListenableFuture<V> future) Starts aClosingFuture
pipeline with aListenableFuture
.static <V extends @Nullable Object>
ClosingFuture<V> ClosingFuture.submit
(ClosingFuture.ClosingCallable<V> callable, Executor executor) Starts aClosingFuture
pipeline by submitting a callable block to an executor.static <V extends @Nullable Object>
ClosingFuture<V> ClosingFuture.submitAsync
(ClosingFuture.AsyncClosingCallable<V> callable, Executor executor) Starts aClosingFuture
pipeline by submitting a callable block to an executor.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.transform
(ClosingFuture.ClosingFunction<? super V, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from this one by applying a function to its value.<U extends @Nullable Object>
ClosingFuture<U> ClosingFuture.transformAsync
(ClosingFuture.AsyncClosingFunction<? super V, U> function, Executor executor) Returns a newClosingFuture
pipeline step derived from this one by applying a function that returns aClosingFuture
to its value.Modifier and TypeMethodDescriptionClosingFuture.Peeker.getDone
(ClosingFuture<D> closingFuture) Returns the value ofclosingFuture
.static ClosingFuture.Combiner
ClosingFuture.whenAllComplete
(ClosingFuture<?> future1, ClosingFuture<?>... moreFutures) Starts specifying how to combineClosingFuture
s into a single pipeline.static ClosingFuture.Combiner
ClosingFuture.whenAllSucceed
(ClosingFuture<?> future1, ClosingFuture<?> future2, ClosingFuture<?> future3, ClosingFuture<?> future4, ClosingFuture<?> future5, ClosingFuture<?> future6, ClosingFuture<?>... moreFutures) Starts specifying how to combineClosingFuture
s into a single pipeline, assuming they all succeed.static <V1 extends @Nullable Object,
V2 extends @Nullable Object>
ClosingFuture.Combiner2<V1, V2> ClosingFuture.whenAllSucceed
(ClosingFuture<V1> future1, ClosingFuture<V2> future2) Starts specifying how to combine twoClosingFuture
s into a single pipeline, assuming they all succeed.static <V1 extends @Nullable Object,
V2 extends @Nullable Object, V3 extends @Nullable Object>
ClosingFuture.Combiner3<V1, V2, V3> ClosingFuture.whenAllSucceed
(ClosingFuture<V1> future1, ClosingFuture<V2> future2, ClosingFuture<V3> future3) Starts specifying how to combine threeClosingFuture
s into a single pipeline, assuming they all succeed.static <V1 extends @Nullable Object,
V2 extends @Nullable Object, V3 extends @Nullable Object, V4 extends @Nullable Object>
ClosingFuture.Combiner4<V1, V2, V3, V4> ClosingFuture.whenAllSucceed
(ClosingFuture<V1> future1, ClosingFuture<V2> future2, ClosingFuture<V3> future3, ClosingFuture<V4> future4) Starts specifying how to combine fourClosingFuture
s into a single pipeline, assuming they all succeed.static <V1 extends @Nullable Object,
V2 extends @Nullable Object, V3 extends @Nullable Object, V4 extends @Nullable Object, V5 extends @Nullable Object>
ClosingFuture.Combiner5<V1, V2, V3, V4, V5> ClosingFuture.whenAllSucceed
(ClosingFuture<V1> future1, ClosingFuture<V2> future2, ClosingFuture<V3> future3, ClosingFuture<V4> future4, ClosingFuture<V5> future5) Starts specifying how to combine fiveClosingFuture
s into a single pipeline, assuming they all succeed.Modifier and TypeMethodDescriptionstatic ClosingFuture.Combiner
ClosingFuture.whenAllComplete
(Iterable<? extends ClosingFuture<?>> futures) Starts specifying how to combineClosingFuture
s into a single pipeline.static ClosingFuture.Combiner
ClosingFuture.whenAllSucceed
(Iterable<? extends ClosingFuture<?>> futures) Starts specifying how to combineClosingFuture
s into a single pipeline, assuming they all succeed.
Future
s of closeable types is dangerous in general because the underlying value may never be closed if theFuture
is canceled after its operation begins.