public interface AsyncClient
| Modifier and Type | Method and Description |
|---|---|
default java.util.stream.Stream<Exception> |
close() |
<T> T |
getClient() |
default boolean |
isRunning() |
void |
registerShutdownHook()
Register the Async clients with shutdown hooks
|
<T> CompletableFuture<HttpResponse<T>> |
request(HttpRequest request,
java.util.function.Function<RawResponse,HttpResponse<T>> transformer,
CompletableFuture<HttpResponse<T>> callback)
Make a Async request
|
<T> T getClient()
T - the underlying client<T> CompletableFuture<HttpResponse<T>> request(HttpRequest request, java.util.function.Function<RawResponse,HttpResponse<T>> transformer, CompletableFuture<HttpResponse<T>> callback)
T - The type of the bodyrequest - the prepared request objecttransformer - the function to transform the responsecallback - the CompletableFuture that will handle the eventual responsedefault java.util.stream.Stream<Exception> close()
default boolean isRunning()
void registerShutdownHook()
Copyright © 2019. All rights reserved.