类的使用
cn.taketoday.web.bind.MethodArgumentNotValidException
-
cn.taketoday.web.handler中MethodArgumentNotValidException的使用
修饰符和类型方法说明protected ResponseEntity<Object>ResponseEntityExceptionHandler.handleMethodArgumentNotValid(MethodArgumentNotValidException ex, HttpHeaders headers, HttpStatusCode status, RequestContext request) Customize the handling ofMethodArgumentNotValidException.protected ObjectSimpleHandlerExceptionHandler.handleMethodArgumentNotValidException(MethodArgumentNotValidException ex, RequestContext request, Object handler) Handle the case where an argument annotated with@Validsuch as anRequestBodyorRequestPartargument fails validation.