public interface HttpProvider extends Closeable
| Modifier and Type | Interface and Description |
|---|---|
static interface |
HttpProvider.HttpRequest
Wrapper for an HTTP request.
|
static interface |
HttpProvider.HttpRequestAuthorizer
Wrapper for authorizing HTTP requests.
|
static interface |
HttpProvider.HttpResponse
Wrapper for HTTP responses.
|
| Modifier and Type | Method and Description |
|---|---|
HttpProvider.HttpResponse |
execute(HttpProvider.HttpRequest httpRequest)
Execute the httpRequest.
|
HttpProvider.HttpRequest |
getRequest(HttpProvider.HttpRequestAuthorizer httpRequestAuthorizer,
String method,
String url,
Map<String,List<String>> formParams)
Gets the RequestBuilder, with the specified method, url, and formParams.
|
HttpProvider.HttpRequest |
getRequest(HttpProvider.HttpRequestAuthorizer httpRequestAuthorizer,
String method,
String url,
String requestBodyJson)
Gets the RequestBuilder, with the specified method, url, and requestBodyJson.
|
HttpProvider.HttpRequest getRequest(HttpProvider.HttpRequestAuthorizer httpRequestAuthorizer, String method, String url, String requestBodyJson)
httpRequestAuthorizer - for adding the Authorization header valuemethod - HTTP method valueurl - HTTP request URLrequestBodyJson - the
Content-Type: application/json
JSON request body.execute(HttpRequest).HttpProvider.HttpRequest getRequest(HttpProvider.HttpRequestAuthorizer httpRequestAuthorizer, String method, String url, Map<String,List<String>> formParams)
httpRequestAuthorizer - for adding the Authorization header valuemethod - HTTP method valueurl - HTTP request URLformParams - the
Content-Type: application/x-www-form-urlencoded
form parameters.execute(HttpRequest).HttpProvider.HttpResponse execute(HttpProvider.HttpRequest httpRequest) throws HttpException, IOException
httpRequest - the HttpRequestHttpException - if there is trouble executing the httpRequestIOException - if there is I/O trouble executing the httpRequestCopyright © 2023 HERE Europe B.V. All Rights Reserved.