Package com.azure.android.core.rest
Class SimpleResponse<T>
- java.lang.Object
- 
- com.azure.android.core.rest.SimpleResponse<T>
 
- 
- Type Parameters:
- T- The deserialized type of the response content.
 - All Implemented Interfaces:
- Response<T>
 - Direct Known Subclasses:
- StreamResponse
 
 public class SimpleResponse<T> extends java.lang.Object implements Response<T> REST response with a strongly-typed content specified.
- 
- 
Constructor SummaryConstructors Constructor Description SimpleResponse(com.azure.android.core.http.HttpRequest request, int statusCode, com.azure.android.core.http.HttpHeaders headers, T value)Creates aSimpleResponse.SimpleResponse(Response<?> response, T value)Creates aSimpleResponsefrom a response and a value.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description com.azure.android.core.http.HttpHeadersgetHeaders()Gets the headers from the HTTP response.com.azure.android.core.http.HttpRequestgetRequest()Gets the request which resulted in thisSimpleResponse.intgetStatusCode()Gets the status code of the HTTP response.TgetValue()Gets the deserialized value of the HTTP response.
 
- 
- 
- 
Constructor Detail- 
SimpleResponsepublic SimpleResponse(com.azure.android.core.http.HttpRequest request, int statusCode, com.azure.android.core.http.HttpHeaders headers, T value)Creates aSimpleResponse.- Parameters:
- request- The request which resulted in this response.
- statusCode- The status code of the HTTP response.
- headers- The headers of the HTTP response.
- value- The deserialized value of the HTTP response.
 
 - 
SimpleResponsepublic SimpleResponse(Response<?> response, T value) Creates aSimpleResponsefrom a response and a value.- Parameters:
- response- The response that needs to be mapped.
- value- The value to put into the new response.
 
 
- 
 - 
Method Detail- 
getRequestpublic com.azure.android.core.http.HttpRequest getRequest() Gets the request which resulted in thisSimpleResponse.- Specified by:
- getRequestin interface- Response<T>
- Returns:
- The request which resulted in this SimpleResponse.
 
 - 
getStatusCodepublic int getStatusCode() Gets the status code of the HTTP response.- Specified by:
- getStatusCodein interface- Response<T>
- Returns:
- The status code of the HTTP response.
 
 - 
getHeaderspublic com.azure.android.core.http.HttpHeaders getHeaders() Gets the headers from the HTTP response.- Specified by:
- getHeadersin interface- Response<T>
- Returns:
- The HTTP response headers.
 
 
- 
 
-