A C D E F G H I J L M N O P Q R S T U V W
All Classes All Packages
All Classes All Packages
All Classes All Packages
A
- accept(T) - Method in interface com.spotify.futures.FuturesExtra.Consumer
-
Performs this operation on the given argument.
- accept(V, Throwable) - Method in class com.spotify.futures.CompletableToApiFutureWrapper
- accept(V, Throwable) - Method in class com.spotify.futures.CompletableToListenableFutureWrapper
- add(Callable<? extends ListenableFuture<T>>) - Method in class com.spotify.futures.ConcurrencyLimiter
-
the callable function will run as soon as the currently active set of futures is less than the maxConcurrency limit.
- add(Callable<? extends ListenableFuture<T>>) - Method in interface com.spotify.futures.FutureJobInvoker
- addCallback(ListenableFuture<T>, FuturesExtra.Consumer<? super T>, FuturesExtra.Consumer<Throwable>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
A lambda-friendly way to attach callbacks to a
ListenableFuture. - addFailureCallback(ListenableFuture<T>, FuturesExtra.Consumer<Throwable>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
A lambda-friendly way to attach a callback to a
ListenableFuture. - addSuccessCallback(ListenableFuture<T>, FuturesExtra.Consumer<? super T>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
A lambda-friendly way to attach a callback to a
ListenableFuture. - ApiFuturesExtra - Class in com.spotify.futures
- ApiFuturesExtra() - Constructor for class com.spotify.futures.ApiFuturesExtra
- ApiFutureToCompletableFutureWrapper<V> - Class in com.spotify.futures
- ApiFutureToCompletableFutureWrapper(ApiFuture<V>, Executor) - Constructor for class com.spotify.futures.ApiFutureToCompletableFutureWrapper
- apply(A, B) - Method in interface com.spotify.futures.FuturesExtra.AsyncFunction2
-
Create and return a
ListenableFuturethat will execute combining a and b into some sort of result. - apply(A, B) - Method in interface com.spotify.futures.FuturesExtra.Function2
-
Combine the inputs into the returned output.
- apply(A, B, C) - Method in interface com.spotify.futures.FuturesExtra.AsyncFunction3
- apply(A, B, C) - Method in interface com.spotify.futures.FuturesExtra.Function3
- apply(A, B, C, D) - Method in interface com.spotify.futures.FuturesExtra.AsyncFunction4
- apply(A, B, C, D) - Method in interface com.spotify.futures.FuturesExtra.Function4
- apply(A, B, C, D, E) - Method in interface com.spotify.futures.FuturesExtra.AsyncFunction5
- apply(A, B, C, D, E) - Method in interface com.spotify.futures.FuturesExtra.Function5
- apply(A, B, C, D, E, F) - Method in interface com.spotify.futures.FuturesExtra.AsyncFunction6
- apply(A, B, C, D, E, F) - Method in interface com.spotify.futures.FuturesExtra.Function6
- apply(Object) - Method in enum com.spotify.futures.CompletableFuturesExtra.Identity
- apply(Object) - Method in enum com.spotify.futures.CompletableFuturesExtra.WrapFunction
- apply(List<Object>) - Method in class com.spotify.futures.JoinedResults.Transform
- AsyncRetrier - Class in com.spotify.futures
-
A helper for retrying asynchronous calls.
- AsyncRetrier(ScheduledExecutorService) - Constructor for class com.spotify.futures.AsyncRetrier
- asyncTransform2(ListenableFuture<A>, ListenableFuture<B>, FuturesExtra.AsyncFunction2<Z, ? super A, ? super B>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- asyncTransform3(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, FuturesExtra.AsyncFunction3<Z, ? super A, ? super B, ? super C>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- asyncTransform4(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, ListenableFuture<D>, FuturesExtra.AsyncFunction4<Z, ? super A, ? super B, ? super C, ? super D>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- asyncTransform5(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, ListenableFuture<D>, ListenableFuture<E>, FuturesExtra.AsyncFunction5<Z, ? super A, ? super B, ? super C, ? super D, ? super E>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- asyncTransform6(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, ListenableFuture<D>, ListenableFuture<E>, ListenableFuture<F>, FuturesExtra.AsyncFunction6<Z, ? super A, ? super B, ? super C, ? super D, ? super E, ? super F>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
C
- callable - Variable in class com.spotify.futures.ConcurrencyLimiter.Job
- cancel(boolean) - Method in class com.spotify.futures.ApiFutureToCompletableFutureWrapper
- cancel(boolean) - Method in class com.spotify.futures.CompletableToApiFutureWrapper
- cancel(boolean) - Method in class com.spotify.futures.CompletableToListenableFutureWrapper
- cancel(boolean) - Method in class com.spotify.futures.ListenableToCompletableFutureWrapper
- CapacityReachedException(String) - Constructor for exception com.spotify.futures.ConcurrencyLimiter.CapacityReachedException
- checkCompleted(ListenableFuture<T>) - Static method in class com.spotify.futures.FuturesExtra
-
check that a future is completed.
- checkCompleted(CompletionStage<T>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
check that a stage is completed.
- com.spotify.futures - module com.spotify.futures
- com.spotify.futures - package com.spotify.futures
- CompletableFuturesExtra - Class in com.spotify.futures
- CompletableFuturesExtra() - Constructor for class com.spotify.futures.CompletableFuturesExtra
- CompletableFuturesExtra.Identity - Enum in com.spotify.futures
- CompletableFuturesExtra.WrapFunction - Enum in com.spotify.futures
- CompletableToApiFutureWrapper<V> - Class in com.spotify.futures
- CompletableToApiFutureWrapper(CompletionStage<V>) - Constructor for class com.spotify.futures.CompletableToApiFutureWrapper
- CompletableToListenableFutureWrapper<V> - Class in com.spotify.futures
- CompletableToListenableFutureWrapper(CompletionStage<V>) - Constructor for class com.spotify.futures.CompletableToListenableFutureWrapper
- ConcurrencyLimiter<T> - Class in com.spotify.futures
-
A ConcurrencyLimiter can be used for efficiently queueing up asynchronous work to only run up to a specific limit of work concurrently.
- ConcurrencyLimiter(Executor, int, int) - Constructor for class com.spotify.futures.ConcurrencyLimiter
- ConcurrencyLimiter.CapacityReachedException - Exception in com.spotify.futures
- ConcurrencyLimiter.Job<T> - Class in com.spotify.futures
- create(Executor, int, int) - Static method in class com.spotify.futures.ConcurrencyLimiter
-
Create a
ConcurrencyLimiterinstance. - create(ScheduledExecutorService) - Static method in class com.spotify.futures.AsyncRetrier
D
- DEFAULT_DELAY_MILLIS - Static variable in class com.spotify.futures.AsyncRetrier
- dereference(CompletionStage<? extends CompletionStage<T>>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
This takes a stage of a stage of a value and returns a plain stage of a value.
E
- exceptionallyCompletedFuture(Throwable) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Returns a new CompletableFuture that is already exceptionally completed with the given exception.
- exceptionallyCompose(CompletionStage<T>, Function<Throwable, ? extends CompletionStage<T>>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Returns a new stage that, when this stage completes exceptionally, is executed with this stage's exception as the argument to the supplied function.
- executor - Variable in class com.spotify.futures.ConcurrencyLimiter
- executorService - Variable in class com.spotify.futures.AsyncRetrier
F
- fastFail(ListenableFuture<B>, ListenableFuture<A>, Validator<B>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
This takes two futures of type
FuturesExtraandFuturesExtraand works like a valve onFuturesExtra, with validation executed onFuturesExtra. - future - Variable in class com.spotify.futures.ApiFutureToCompletableFutureWrapper
- future - Variable in class com.spotify.futures.CompletableToApiFutureWrapper
- future - Variable in class com.spotify.futures.CompletableToListenableFutureWrapper
- future - Variable in class com.spotify.futures.ListenableToCompletableFutureWrapper
- FutureJobInvoker<T> - Interface in com.spotify.futures
- futures - Variable in class com.spotify.futures.JoinedResults
- futures - Variable in class com.spotify.futures.JoinedResults.Transform
- FuturesExtra - Class in com.spotify.futures
-
Static utility methods pertaining to the
ListenableFutureinterface. - FuturesExtra() - Constructor for class com.spotify.futures.FuturesExtra
- FuturesExtra.AsyncFunction2<Z,A,B> - Interface in com.spotify.futures
-
Implementations of this interface is used inĀ
FuturesExtra.syncTransform2(com.google.common.util.concurrent.ListenableFuture<A>, com.google.common.util.concurrent.ListenableFuture<B>, com.spotify.futures.FuturesExtra.Function2<Z, ? super A, ? super B>, java.util.concurrent.Executor)to asynchronously transform two values into a return value. - FuturesExtra.AsyncFunction3<Z,A,B,C> - Interface in com.spotify.futures
- FuturesExtra.AsyncFunction4<Z,A,B,C,D> - Interface in com.spotify.futures
- FuturesExtra.AsyncFunction5<Z,A,B,C,D,E> - Interface in com.spotify.futures
- FuturesExtra.AsyncFunction6<Z,A,B,C,D,E,F> - Interface in com.spotify.futures
- FuturesExtra.Consumer<T> - Interface in com.spotify.futures
-
Represents an operation that accepts a single input argument and returns no result.
- FuturesExtra.Function2<Z,A,B> - Interface in com.spotify.futures
-
Implementations of this interface is used to synchronously transform the input values into an output value.
- FuturesExtra.Function3<Z,A,B,C> - Interface in com.spotify.futures
-
Implementations of this interface is used to synchronously transform the input values into an output value.
- FuturesExtra.Function4<Z,A,B,C,D> - Interface in com.spotify.futures
-
Implementations of this interface is used to synchronously transform the input values into an output value.
- FuturesExtra.Function5<Z,A,B,C,D,E> - Interface in com.spotify.futures
-
Implementations of this interface is used to synchronously transform the input values into an output value.
- FuturesExtra.Function6<Z,A,B,C,D,E,F> - Interface in com.spotify.futures
-
Implementations of this interface is used to synchronously transform the input values into an output value.
G
- get(ListenableFuture<T>) - Method in class com.spotify.futures.JoinedResults
-
Gets a future value if it was part of the joined future values, else throws an illegal argument exception.
- getCompleted(ListenableFuture<T>) - Static method in class com.spotify.futures.FuturesExtra
-
Get the value of a completed future.
- getCompleted(CompletionStage<T>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Get the value of a completed stage.
- getException(ListenableFuture<T>) - Static method in class com.spotify.futures.FuturesExtra
-
Get the exception of a completed future.
- grabJob() - Method in class com.spotify.futures.ConcurrencyLimiter
-
Return a
Jobwith acquired permit,nullotherwise.
H
- handleCompose(CompletionStage<T>, BiFunction<? super T, Throwable, ? extends CompletionStage<U>>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Returns a new stage that, when this stage completes either normally or exceptionally, is executed with this stage's result and exception as arguments to the supplied function.
- handleFailure(SettableFuture<T>, Supplier<ListenableFuture<T>>, int, long, TimeUnit, Predicate<T>, Throwable) - Method in class com.spotify.futures.AsyncRetrier
I
- Identity() - Constructor for enum com.spotify.futures.CompletableFuturesExtra.Identity
- INSTANCE - com.spotify.futures.CompletableFuturesExtra.Identity
- INSTANCE - com.spotify.futures.CompletableFuturesExtra.WrapFunction
- INSTANCE - com.spotify.futures.JoinedResults.Null
- invoke(SettableFuture<T>, Callable<? extends ListenableFuture<T>>) - Method in class com.spotify.futures.ConcurrencyLimiter
J
- Job(Callable<? extends ListenableFuture<T>>, SettableFuture<T>) - Constructor for class com.spotify.futures.ConcurrencyLimiter.Job
- join(Executor, ListenableFuture<?>...) - Static method in class com.spotify.futures.FuturesExtra
-
Transform a list of futures to a future that returns a joined result of them all.
- join(Executor, List<? extends ListenableFuture<?>>) - Static method in class com.spotify.futures.FuturesExtra
-
Transform a list of futures to a future that returns a joined result of them all.
- JoinedResults - Class in com.spotify.futures
-
Contains references to a set of joined future values.
- JoinedResults(Map<ListenableFuture<?>, Object>) - Constructor for class com.spotify.futures.JoinedResults
- JoinedResults.Null - Enum in com.spotify.futures
- JoinedResults.Transform - Class in com.spotify.futures
L
- limit - Variable in class com.spotify.futures.ConcurrencyLimiter
- ListenableFuturesExtra - Class in com.spotify.futures
- ListenableFuturesExtra() - Constructor for class com.spotify.futures.ListenableFuturesExtra
- ListenableToCompletableFutureWrapper<V> - Class in com.spotify.futures
- ListenableToCompletableFutureWrapper(ListenableFuture<V>) - Constructor for class com.spotify.futures.ListenableToCompletableFutureWrapper
M
- makeTimeoutFuture(ScheduledExecutorService, ListenableFuture<T>, long, TimeUnit) - Static method in class com.spotify.futures.FuturesExtra
-
Returns a future that fails with a
TimeoutExceptionif the parent future has not finished before the timeout. - maxConcurrency - Variable in class com.spotify.futures.ConcurrencyLimiter
- maxQueueSize - Variable in class com.spotify.futures.ConcurrencyLimiter
N
- Null() - Constructor for enum com.spotify.futures.JoinedResults.Null
- numActive() - Method in class com.spotify.futures.ConcurrencyLimiter
-
Return the number of currently active futures that have not yet completed.
- numQueued() - Method in class com.spotify.futures.ConcurrencyLimiter
-
Return the number of callables that are queued up and haven't started yet.
O
- onFailure(Throwable) - Method in class com.spotify.futures.ApiFutureToCompletableFutureWrapper
- onFailure(Throwable) - Method in class com.spotify.futures.ListenableToCompletableFutureWrapper
- onSuccess(V) - Method in class com.spotify.futures.ApiFutureToCompletableFutureWrapper
- onSuccess(V) - Method in class com.spotify.futures.ListenableToCompletableFutureWrapper
P
- pump() - Method in class com.spotify.futures.ConcurrencyLimiter
Q
- queue - Variable in class com.spotify.futures.ConcurrencyLimiter
R
- remainingActiveCapacity() - Method in class com.spotify.futures.ConcurrencyLimiter
-
Return the number of additional callables that can be run without queueing.
- remainingQueueCapacity() - Method in class com.spotify.futures.ConcurrencyLimiter
-
Return the number of additional callables that can be queued before failing.
- response - Variable in class com.spotify.futures.ConcurrencyLimiter.Job
- retry(Supplier<ListenableFuture<T>>, int) - Method in class com.spotify.futures.AsyncRetrier
- retry(Supplier<ListenableFuture<T>>, int, long) - Method in class com.spotify.futures.AsyncRetrier
- retry(Supplier<ListenableFuture<T>>, int, long, TimeUnit) - Method in class com.spotify.futures.AsyncRetrier
- retry(Supplier<ListenableFuture<T>>, int, long, TimeUnit, Predicate<T>) - Method in class com.spotify.futures.AsyncRetrier
-
Retry
codeup toretriestimes.
S
- select(List<? extends ListenableFuture<T>>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Returns a new
ListenableFuturewith the result of the first of futures that successfully completes. - startRetry(SettableFuture<T>, Supplier<ListenableFuture<T>>, int, long, TimeUnit, Predicate<T>) - Method in class com.spotify.futures.AsyncRetrier
- syncTransform2(ListenableFuture<A>, ListenableFuture<B>, FuturesExtra.Function2<Z, ? super A, ? super B>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- syncTransform3(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, FuturesExtra.Function3<Z, ? super A, ? super B, ? super C>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- syncTransform4(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, ListenableFuture<D>, FuturesExtra.Function4<Z, ? super A, ? super B, ? super C, ? super D>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- syncTransform5(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, ListenableFuture<D>, ListenableFuture<E>, FuturesExtra.Function5<Z, ? super A, ? super B, ? super C, ? super D, ? super E>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
- syncTransform6(ListenableFuture<A>, ListenableFuture<B>, ListenableFuture<C>, ListenableFuture<D>, ListenableFuture<E>, ListenableFuture<F>, FuturesExtra.Function6<Z, ? super A, ? super B, ? super C, ? super D, ? super E, ? super F>, Executor) - Static method in class com.spotify.futures.FuturesExtra
-
Transform the input futures into a single future, using the provided transform function.
T
- toApiFuture(CompletionStage<V>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Wrap a
CompletionStagein aApiFuture. - toCompletableFuture(ApiFuture<V>) - Static method in class com.spotify.futures.ApiFuturesExtra
-
Converts an
ApiFutureto aCompletableFuture. - toCompletableFuture(ApiFuture<V>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Deprecated.
- toCompletableFuture(ApiFuture<V>, Executor) - Static method in class com.spotify.futures.ApiFuturesExtra
-
Converts an
ApiFutureto aCompletableFuture. - toCompletableFuture(ApiFuture<V>, Executor) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Deprecated.
- toCompletableFuture(ListenableFuture<V>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Deprecated.
- toCompletableFuture(ListenableFuture<V>) - Static method in class com.spotify.futures.ListenableFuturesExtra
-
Wrap a
ListenableFuturein aCompletableFuture. - toListenableFuture(CompletableFuture<V>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Wrap a
CompletableFuturein aListenableFuture. - toListenableFuture(CompletionStage<V>) - Static method in class com.spotify.futures.CompletableFuturesExtra
-
Wrap a
CompletionStagein aListenableFuture. - transform(List<? extends ListenableFuture<?>>, Function<List<Object>, Z>, Executor) - Static method in class com.spotify.futures.FuturesExtra
- transform(List<? extends ListenableFuture<?>>, AsyncFunction<List<Object>, Z>, Executor) - Static method in class com.spotify.futures.FuturesExtra
- Transform(List<? extends ListenableFuture<?>>) - Constructor for class com.spotify.futures.JoinedResults.Transform
U
- unwrap() - Method in class com.spotify.futures.ApiFutureToCompletableFutureWrapper
- unwrap() - Method in class com.spotify.futures.CompletableToApiFutureWrapper
- unwrap() - Method in class com.spotify.futures.CompletableToListenableFutureWrapper
- unwrap() - Method in class com.spotify.futures.ListenableToCompletableFutureWrapper
- unwrapThrowable(Throwable) - Static method in class com.spotify.futures.CompletableToListenableFutureWrapper
V
- validate(T) - Method in interface com.spotify.futures.Validator
- Validator<T> - Interface in com.spotify.futures
-
Validate a value, throw an exception on invalid values.
- valueOf(String) - Static method in enum com.spotify.futures.CompletableFuturesExtra.Identity
-
Returns the enum constant of this type with the specified name.
- valueOf(String) - Static method in enum com.spotify.futures.CompletableFuturesExtra.WrapFunction
-
Returns the enum constant of this type with the specified name.
- valueOf(String) - Static method in enum com.spotify.futures.JoinedResults.Null
-
Returns the enum constant of this type with the specified name.
- values() - Static method in enum com.spotify.futures.CompletableFuturesExtra.Identity
-
Returns an array containing the constants of this enum type, in the order they are declared.
- values() - Static method in enum com.spotify.futures.CompletableFuturesExtra.WrapFunction
-
Returns an array containing the constants of this enum type, in the order they are declared.
- values() - Static method in enum com.spotify.futures.JoinedResults.Null
-
Returns an array containing the constants of this enum type, in the order they are declared.
W
- wrap(CompletionStage<T>) - Static method in class com.spotify.futures.CompletableFuturesExtra
- WrapFunction() - Constructor for enum com.spotify.futures.CompletableFuturesExtra.WrapFunction
All Classes All Packages