@ControllerAdvice public class ValidationAwareRestExceptionHandlers extends BaseRestExceptionHandlers
| Modifier and Type | Field and Description |
|---|---|
protected ResourceBundle |
errorMessageBundle |
| Constructor and Description |
|---|
ValidationAwareRestExceptionHandlers() |
| Modifier and Type | Method and Description |
|---|---|
org.springframework.http.ResponseEntity<Object> |
handleGeneralException(Exception ex,
org.springframework.web.context.request.WebRequest webRequest) |
protected org.springframework.http.ResponseEntity<Object> |
handleHttpMessageNotReadable(org.springframework.http.converter.HttpMessageNotReadableException ex,
org.springframework.http.HttpHeaders headers,
org.springframework.http.HttpStatus status,
org.springframework.web.context.request.WebRequest webRequest) |
protected org.springframework.http.ResponseEntity<Object> |
handleMethodArgumentNotValid(org.springframework.web.bind.MethodArgumentNotValidException ex,
org.springframework.http.HttpHeaders headers,
org.springframework.http.HttpStatus status,
org.springframework.web.context.request.WebRequest request) |
org.springframework.http.ResponseEntity<Object> |
handleValidationException(ValidationException ex,
org.springframework.web.context.request.WebRequest request) |
void |
setErrorMessageBundle(ResourceBundle errorMessageBundle) |
handleExceptionInternal, handleExceptionInternalhandleAsyncRequestTimeoutException, handleBindException, handleConversionNotSupported, handleException, handleHttpMediaTypeNotAcceptable, handleHttpMediaTypeNotSupported, handleHttpMessageNotWritable, handleHttpRequestMethodNotSupported, handleMissingPathVariable, handleMissingServletRequestParameter, handleMissingServletRequestPart, handleNoHandlerFoundException, handleNoSuchRequestHandlingMethod, handleServletRequestBindingException, handleTypeMismatchprotected ResourceBundle errorMessageBundle
public ValidationAwareRestExceptionHandlers()
public void setErrorMessageBundle(ResourceBundle errorMessageBundle)
@ExceptionHandler(value=ValidationException.class) public org.springframework.http.ResponseEntity<Object> handleValidationException(ValidationException ex, org.springframework.web.context.request.WebRequest request)
protected org.springframework.http.ResponseEntity<Object> handleHttpMessageNotReadable(org.springframework.http.converter.HttpMessageNotReadableException ex, org.springframework.http.HttpHeaders headers, org.springframework.http.HttpStatus status, org.springframework.web.context.request.WebRequest webRequest)
handleHttpMessageNotReadable in class org.springframework.web.servlet.mvc.method.annotation.ResponseEntityExceptionHandlerprotected org.springframework.http.ResponseEntity<Object> handleMethodArgumentNotValid(org.springframework.web.bind.MethodArgumentNotValidException ex, org.springframework.http.HttpHeaders headers, org.springframework.http.HttpStatus status, org.springframework.web.context.request.WebRequest request)
handleMethodArgumentNotValid in class org.springframework.web.servlet.mvc.method.annotation.ResponseEntityExceptionHandler@ExceptionHandler(value=java.lang.Exception.class) public org.springframework.http.ResponseEntity<Object> handleGeneralException(Exception ex, org.springframework.web.context.request.WebRequest webRequest)
handleGeneralException in class BaseRestExceptionHandlersCopyright © 2019 CrafterCMS. All rights reserved.