Refit.ApiResponse<T>
Implementation of IApiResponse<T> that provides additional functionalities.
Gets the deserialized response content as T.
Gets the HTTP response content headers as defined in RFC 2616.
Gets the ApiExceptionBase object in case of unsuccessful request or response.
Gets a value indicating whether deserialized Content is available.
Gets the HTTP response headers.
Gets a value indicating whether the request was successful and deserialized Content is available.
Gets the reason phrase which typically is sent by the server together with the status code.
Gets the HTTP Request message which led to this response.
Gets the Refit settings used to send the request.
Gets the HTTP response status code.
Gets the HTTP Message version.
public ApiResponse(HttpRequestMessage request, HttpResponseMessage response, T content, RefitSettings settings, ApiExceptionBase error = null)
Implementation of IApiResponse<T> that provides additional functionalities.
Initializes a new instance of the ApiResponse<T> class.
public ApiResponse(HttpResponseMessage response, T content, RefitSettings settings, ApiExceptionBase error)
Initializes a new instance of the ApiResponse<T> class.
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Ensures the request was successful and without any other error by throwing an exception in case of failure.
Ensures the request was successful by throwing an exception in case of failure.