| Package | Description |
|---|---|
| com.microsoft.rest.v2 |
The package contains the runtime classes required for AutoRest generated
clients to compile and function.
|
| com.microsoft.rest.v2.http |
This package contains the HTTP abstractions between the AnnotationParser's RestProxy and whatever
HTTP client we choose to use.
|
| com.microsoft.rest.v2.policy |
Code related to creating proxy implementations of interfaces that have been generated from
Swagger specifications.
|
| com.microsoft.rest.v2.protocol |
The package contains classes that interfaces defining the behaviors
of the necessary components of a Rest Client.
|
| Modifier and Type | Method and Description |
|---|---|
HttpResponse |
RestException.response() |
| Modifier and Type | Method and Description |
|---|---|
io.reactivex.Single<HttpResponse> |
RestProxy.ensureExpectedStatus(HttpResponse response,
SwaggerMethodParser methodParser,
int[] additionalAllowedStatusCodes)
Ensure that the provided HttpResponse has a status code that is defined in the provided
SwaggerMethodParser or is in the int[] of additional allowed status codes.
|
io.reactivex.Single<HttpResponse> |
RestProxy.sendHttpRequestAsync(HttpRequest request)
Send the provided request asynchronously, applying any request policies provided to the HttpClient instance.
|
| Modifier and Type | Method and Description |
|---|---|
io.reactivex.Single<HttpResponse> |
RestProxy.ensureExpectedStatus(HttpResponse response,
SwaggerMethodParser methodParser,
int[] additionalAllowedStatusCodes)
Ensure that the provided HttpResponse has a status code that is defined in the provided
SwaggerMethodParser or is in the int[] of additional allowed status codes.
|
protected io.reactivex.Maybe<?> |
RestProxy.handleBodyReturnTypeAsync(HttpResponse response,
SwaggerMethodParser methodParser,
Type entityType) |
| Modifier and Type | Method and Description |
|---|---|
protected Object |
RestProxy.handleAsyncHttpResponse(HttpRequest httpRequest,
io.reactivex.Single<HttpResponse> asyncHttpResponse,
SwaggerMethodParser methodParser,
Type returnType) |
Object |
RestProxy.handleRestReturnType(HttpRequest httpRequest,
io.reactivex.Single<HttpResponse> asyncHttpResponse,
SwaggerMethodParser methodParser,
Type returnType)
Handle the provided asynchronous HTTP response and return the deserialized value.
|
| Constructor and Description |
|---|
RestException(String message,
HttpResponse response)
Initializes a new instance of the RestException class.
|
RestException(String message,
HttpResponse response,
Object body)
Initializes a new instance of the RestException class.
|
RestException(String message,
HttpResponse response,
Throwable cause)
Initializes a new instance of the RestException class.
|
| Modifier and Type | Class and Description |
|---|---|
class |
BufferedHttpResponse
HTTP response which will buffer the response's body when/if it is read.
|
| Modifier and Type | Method and Description |
|---|---|
HttpResponse |
HttpResponse.withDeserializedBody(Object deserializedBody)
Sets the deserialized body on this HttpResponse.
|
HttpResponse |
BufferedHttpResponse.withDeserializedBody(Object deserializedBody) |
HttpResponse |
HttpResponse.withDeserializedHeaders(Object deserializedHeaders)
Set the deserialized headers on this HttpResponse.
|
HttpResponse |
BufferedHttpResponse.withDeserializedHeaders(Object deserializedHeaders) |
HttpResponse |
HttpResponse.withRequest(HttpRequest request)
Sets the request on this HttpResponse.
|
| Modifier and Type | Method and Description |
|---|---|
io.reactivex.Single<HttpResponse> |
NettyClient.sendRequestAsync(HttpRequest request) |
io.reactivex.Single<HttpResponse> |
HttpPipeline.sendRequestAsync(HttpRequest httpRequest)
Send the provided HTTP request using this HttpPipeline's HttpClient after it has passed through
each of the RequestPolicies that have been configured on this HttpPipeline.
|
abstract io.reactivex.Single<HttpResponse> |
HttpClient.sendRequestAsync(HttpRequest request)
Send the provided request asynchronously, applying any request policies provided to the HttpClient instance.
|
| Constructor and Description |
|---|
BufferedHttpResponse(HttpResponse innerHttpResponse)
Creates a buffered HTTP response.
|
| Modifier and Type | Method and Description |
|---|---|
io.reactivex.Single<HttpResponse> |
RequestPolicy.sendAsync(HttpRequest request)
Sends an HTTP request as an asynchronous operation.
|
io.reactivex.Single<HttpResponse> |
HttpClientRequestPolicyAdapter.sendAsync(HttpRequest request) |
| Modifier and Type | Method and Description |
|---|---|
io.reactivex.Single<HttpResponse> |
HttpResponseDecoder.decode(HttpResponse response)
Asynchronously decodes an
HttpResponse, deserializing into a response or error value. |
| Modifier and Type | Method and Description |
|---|---|
io.reactivex.Single<HttpResponse> |
HttpResponseDecoder.decode(HttpResponse response)
Asynchronously decodes an
HttpResponse, deserializing into a response or error value. |
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*/