public class HttpClientErrorException extends HttpStatusCodeException
DefaultResponseErrorHandler
,
Serialized FormModifier and Type | Field and Description |
---|---|
private static long |
serialVersionUID |
Constructor and Description |
---|
HttpClientErrorException(HttpStatus statusCode)
Constructor with a status code only.
|
HttpClientErrorException(HttpStatus statusCode,
java.lang.String statusText)
Constructor with a status code and status text.
|
HttpClientErrorException(HttpStatus statusCode,
java.lang.String statusText,
byte[] body,
java.nio.charset.Charset responseCharset)
Constructor with a status code and status text, and content.
|
HttpClientErrorException(HttpStatus statusCode,
java.lang.String statusText,
HttpHeaders headers,
byte[] body,
java.nio.charset.Charset responseCharset)
Constructor with a status code and status text, headers, and content.
|
Modifier and Type | Method and Description |
---|---|
static HttpClientErrorException |
create(HttpStatus statusCode,
java.lang.String statusText,
HttpHeaders headers,
byte[] body,
java.nio.charset.Charset charset)
Create
HttpClientErrorException or an HTTP status specific sub-class. |
getStatusCode
getRawStatusCode, getResponseBodyAsByteArray, getResponseBodyAsString, getResponseHeaders, getStatusText
contains, getMessage, getMostSpecificCause, getRootCause
private static final long serialVersionUID
public HttpClientErrorException(HttpStatus statusCode)
public HttpClientErrorException(HttpStatus statusCode, java.lang.String statusText)
public HttpClientErrorException(HttpStatus statusCode, java.lang.String statusText, @Nullable byte[] body, @Nullable java.nio.charset.Charset responseCharset)
public HttpClientErrorException(HttpStatus statusCode, java.lang.String statusText, @Nullable HttpHeaders headers, @Nullable byte[] body, @Nullable java.nio.charset.Charset responseCharset)
public static HttpClientErrorException create(HttpStatus statusCode, java.lang.String statusText, HttpHeaders headers, byte[] body, @Nullable java.nio.charset.Charset charset)
HttpClientErrorException
or an HTTP status specific sub-class.