public class ResponseStatusException extends NestedRuntimeException
| Constructor and Description |
|---|
ResponseStatusException(HttpStatus status,
String reason)
Constructor with a response code and a reason to add to the exception
message as explanation.
|
ResponseStatusException(HttpStatus status,
String reason,
Throwable cause)
Constructor with a nested exception.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getReason()
The reason explaining the exception.
|
HttpStatus |
getStatus()
The HTTP status that fits the exception.
|
contains, getMessage, getMostSpecificCause, getRootCauseaddSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toStringpublic ResponseStatusException(HttpStatus status, String reason)
public ResponseStatusException(HttpStatus status, String reason, Throwable cause)
public HttpStatus getStatus()
public String getReason()