public interface ProblemHandling extends GeneralAdviceTrait, HttpAdviceTrait, IOAdviceTrait, RoutingAdviceTrait, SecurityAdviceTrait, ValidationAdviceTrait
ProblemHandling is a composite AdviceTrait that combines all built-in advice traits into a single
interface that makes it easier to use:
@ControllerAdvice
public class ExceptionHandling implements ProblemHandling
Note: Future versions of this class will be extended with additional traits.
LOG| Modifier and Type | Method and Description |
|---|---|
default org.zalando.problem.StatusType |
defaultConstraintViolationStatus() |
default URI |
defaultConstraintViolationType() |
default String |
formatFieldName(String fieldName)
Format the name of a violating field (e.g.
|
default org.springframework.http.ResponseEntity<org.zalando.problem.Problem> |
newConstraintViolationProblem(Throwable throwable,
Collection<Violation> stream,
org.springframework.web.context.request.NativeWebRequest request) |
handleProblemhandleThrowablehandleUnsupportedOperationhandleMediaTypeNotAcceptablehandleMediaTypeNotSupportedExceptionhandleRequestMethodNotSupportedExceptionhandleMessageNotReadableExceptionhandleMultiparthandleTypeMismatchhandleMissingServletRequestParameterhandleMissingServletRequestParthandleNoHandlerFoundhandleServletRequestBindinghandleAuthenticationhandleAccessDeniedcreateViolation, handleConstraintViolationhandleBindingResulthandleMethodArgumentNotValidcreateViolation, createViolation, createViolationsdefault URI defaultConstraintViolationType()
default org.zalando.problem.StatusType defaultConstraintViolationStatus()
default String formatFieldName(String fieldName)
fieldName - the field name to formatdefault org.springframework.http.ResponseEntity<org.zalando.problem.Problem> newConstraintViolationProblem(Throwable throwable, Collection<Violation> stream, org.springframework.web.context.request.NativeWebRequest request)
Copyright © 2015–2017 Zalando SE. All rights reserved.