public class HttpServerErrorException extends HttpStatusCodeException
DefaultResponseErrorHandler
,
Serialized FormModifier and Type | Class and Description |
---|---|
static class |
HttpServerErrorException.BadGateway
HttpServerErrorException for HTTP status 502 Bad Gateway. |
static class |
HttpServerErrorException.GatewayTimeout
HttpServerErrorException for status HTTP 504 Gateway Timeout. |
static class |
HttpServerErrorException.InternalServerError
HttpServerErrorException for status HTTP 500 Internal Server Error. |
static class |
HttpServerErrorException.NotImplemented
HttpServerErrorException for status HTTP 501 Not Implemented. |
static class |
HttpServerErrorException.ServiceUnavailable
HttpServerErrorException for status HTTP 503 Service Unavailable. |
Constructor and Description |
---|
HttpServerErrorException(HttpStatus statusCode)
Constructor with a status code only.
|
HttpServerErrorException(HttpStatus statusCode,
String statusText)
Constructor with a status code and status text.
|
HttpServerErrorException(HttpStatus statusCode,
String statusText,
byte[] body,
Charset charset)
Constructor with a status code and status text, and content.
|
HttpServerErrorException(HttpStatus statusCode,
String statusText,
HttpHeaders headers,
byte[] body,
Charset charset)
Constructor with a status code and status text, headers, and content.
|
HttpServerErrorException(String message,
HttpStatus statusCode,
String statusText,
HttpHeaders headers,
byte[] body,
Charset charset)
Constructor with a status code and status text, headers, content, and a
prepared message.
|
Modifier and Type | Method and Description |
---|---|
static HttpServerErrorException |
create(HttpStatus statusCode,
String statusText,
HttpHeaders headers,
byte[] body,
Charset charset)
Create an
HttpServerErrorException or an HTTP status specific subclass. |
static HttpServerErrorException |
create(String message,
HttpStatus statusCode,
String statusText,
HttpHeaders headers,
byte[] body,
Charset charset)
Variant of
create(String, HttpStatus, String, HttpHeaders, byte[], Charset)
with an optional prepared message. |
getStatusCode
getRawStatusCode, getResponseBodyAsByteArray, getResponseBodyAsString, getResponseBodyAsString, getResponseHeaders, getStatusText
contains, getMessage, getMostSpecificCause, getRootCause
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public HttpServerErrorException(HttpStatus statusCode)
public HttpServerErrorException(HttpStatus statusCode, String statusText)
public HttpServerErrorException(HttpStatus statusCode, String statusText, @Nullable byte[] body, @Nullable Charset charset)
public HttpServerErrorException(HttpStatus statusCode, String statusText, @Nullable HttpHeaders headers, @Nullable byte[] body, @Nullable Charset charset)
public HttpServerErrorException(String message, HttpStatus statusCode, String statusText, @Nullable HttpHeaders headers, @Nullable byte[] body, @Nullable Charset charset)
public static HttpServerErrorException create(HttpStatus statusCode, String statusText, HttpHeaders headers, byte[] body, @Nullable Charset charset)
HttpServerErrorException
or an HTTP status specific subclass.public static HttpServerErrorException create(@Nullable String message, HttpStatus statusCode, String statusText, HttpHeaders headers, byte[] body, @Nullable Charset charset)
create(String, HttpStatus, String, HttpHeaders, byte[], Charset)
with an optional prepared message.