ResponseType - resource from server.ExceptionType - in case of a problem or the connection was aborted.public final class ApiCall<ResponseType,ExceptionType extends CoreApiException> extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
ApiCall.Builder<ResponseType,ExceptionType extends CoreApiException>
Builder class for the
ApiCall class. |
| Modifier and Type | Method and Description |
|---|---|
ResponseType |
execute()
Execute the ApiCall and returns the expected response.
|
CompletableFuture<ResponseType> |
executeAsync()
Execute the Api call asynchronously and returns the expected response in CompletableFuture.
|
public ResponseType execute() throws IOException, ExceptionType extends CoreApiException
IOException - Signals that an I/O exception of some sort has occurred.ExceptionType - Represents error response from the server.ExceptionType extends CoreApiExceptionpublic CompletableFuture<ResponseType> executeAsync()
CompletableFuture.Copyright © 2023. All rights reserved.