Interface Response
@Beta
public interface Response
HTTP Response wrapper.
-
Method Summary
Modifier and TypeMethodDescriptiongetBody()Get the response body.<T> TGet the response body, casting it into the expected type.Get the error exception, if present.Get the response headers.intGet the response code.default booleanisError()Returns whether or not the request had an error (4xx/5xx response code or underlying IOException)
-
Method Details
-
getBody
InputStream getBody()Get the response body. -
getBody
Get the response body, casting it into the expected type. -
getException
Get the error exception, if present. -
getStatusCode
int getStatusCode()Get the response code. -
getHeaders
Get the response headers. -
isError
default boolean isError()Returns whether or not the request had an error (4xx/5xx response code or underlying IOException)
-