-
- All Implemented Interfaces:
public interface ResponseHTTP response.
-
-
Method Summary
Modifier and Type Method Description abstract IntegergetStatusCode()HTTP status code of the response. abstract StringgetReasonPhrase()HTTP status message of the response. abstract Iterable<Pair<String, String>>getHeaders()HTTP response headers, if any were delivered. abstract BufferedSourcegetBody()HTTP response data source, if available. abstract Iterable<Pair<String, String>>getTrailers()HTTP response trailers, if any were delivered. abstract RequestgetRequest()HTTP request after API rewrites and/or HTTP redirects. -
-
Method Detail
-
getStatusCode
abstract Integer getStatusCode()
HTTP status code of the response.
-
getReasonPhrase
abstract String getReasonPhrase()
HTTP status message of the response.
Some implementations (e.g. JDK HTTP Client) do not support reporting the reason phrase. When not supported a standard phrase will be provided unless there is no standard phrase, in which case
nullwill be returned.
-
getHeaders
abstract Iterable<Pair<String, String>> getHeaders()
HTTP response headers, if any were delivered.
-
getBody
abstract BufferedSource getBody()
HTTP response data source, if available.
Response.body will be null if the body data is not yet available; as when the response is provided by a Request.Event.Start event.
-
getTrailers
abstract Iterable<Pair<String, String>> getTrailers()
HTTP response trailers, if any were delivered.
Response.trailers will be null if the trailers are not yet available. Trailers won't be available until the Response.body has been consumed and closed or when the response is provided by a Request.Event.Start event.
-
getRequest
abstract Request getRequest()
HTTP request after API rewrites and/or HTTP redirects.
-
-
-
-