@Target(value={TYPE,METHOD})
@Retention(value=RUNTIME)
@Documented
public @interface ResponseStatus
ResponseStatusExceptionResolver
Modifier and Type | Required Element and Description |
---|---|
HttpStatus |
value
The status code to use for the response.
|
Modifier and Type | Optional Element and Description |
---|---|
java.lang.String |
reason
The reason to be used for the response.
|
public abstract HttpStatus value
javax.servlet.http.HttpServletResponse#setStatus(int)
public abstract java.lang.String reason
If this element is not set, it will default to the standard status message for the status code.
javax.servlet.http.HttpServletResponse#sendError(int, String)