T - the type of the returning objectpublic class ServiceFuture<T> extends CompletableFuture<T>
CompletableFuture.AsynchronousCompletionTask| Modifier | Constructor and Description |
|---|---|
protected |
ServiceFuture() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
cancel(boolean mayInterruptIfRunning) |
static ServiceFuture<Void> |
fromBody(io.reactivex.Completable completable,
ServiceCallback<Void> callback)
Creates a ServiceFuture from an Completable object and a callback.
|
static <T> ServiceFuture<T> |
fromBody(io.reactivex.Maybe<T> maybe,
ServiceCallback<T> callback)
Creates a ServiceCall from a Single object and a callback.
|
static <T> ServiceFuture<T> |
fromBody(io.reactivex.Single<T> single,
ServiceCallback<T> callback)
Creates a ServiceCall from a Single object and a callback.
|
io.reactivex.disposables.Disposable |
getSubscription() |
boolean |
isCancelled() |
protected void |
setSubscription(io.reactivex.disposables.Disposable subscription) |
acceptEither, acceptEitherAsync, acceptEitherAsync, allOf, anyOf, applyToEither, applyToEitherAsync, applyToEitherAsync, complete, completedFuture, completeExceptionally, exceptionally, get, get, getNow, getNumberOfDependents, handle, handleAsync, handleAsync, isCompletedExceptionally, isDone, join, obtrudeException, obtrudeValue, runAfterBoth, runAfterBothAsync, runAfterBothAsync, runAfterEither, runAfterEitherAsync, runAfterEitherAsync, runAsync, runAsync, supplyAsync, supplyAsync, thenAccept, thenAcceptAsync, thenAcceptAsync, thenAcceptBoth, thenAcceptBothAsync, thenAcceptBothAsync, thenApply, thenApplyAsync, thenApplyAsync, thenCombine, thenCombineAsync, thenCombineAsync, thenCompose, thenComposeAsync, thenComposeAsync, thenRun, thenRunAsync, thenRunAsync, toCompletableFuture, toString, whenComplete, whenCompleteAsync, whenCompleteAsyncpublic static <T> ServiceFuture<T> fromBody(io.reactivex.Single<T> single, ServiceCallback<T> callback)
T - the type of the responsesingle - the single to create fromcallback - the callback to call when events happenpublic static <T> ServiceFuture<T> fromBody(io.reactivex.Maybe<T> maybe, ServiceCallback<T> callback)
T - the type of the responsemaybe - the maybe to create fromcallback - the callback to call when events happenpublic static ServiceFuture<Void> fromBody(io.reactivex.Completable completable, ServiceCallback<Void> callback)
completable - the completable to create fromcallback - the callback to call when event happenpublic io.reactivex.disposables.Disposable getSubscription()
protected void setSubscription(io.reactivex.disposables.Disposable subscription)
public boolean cancel(boolean mayInterruptIfRunning)
public boolean isCancelled()
isCancelled in interface Future<T>isCancelled in class CompletableFuture<T>/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*/