@RestControllerAdvice public class CodeExceptionHandler extends Object
| 构造器和说明 |
|---|
CodeExceptionHandler() |
| 限定符和类型 | 方法和说明 |
|---|---|
CodeResult |
handleCodeException(CodeException e) |
CodeResult |
handleException(Exception e) |
CodeResult |
handleIllegalArgumentException(IllegalArgumentException e) |
CodeResult |
handleNullPointerException(NullPointerException e) |
CodeResult |
handlerHttpMediaTypeNotSupportedException(org.springframework.web.HttpMediaTypeNotSupportedException e) |
CodeResult |
handlerNoFoundException(org.springframework.web.servlet.NoHandlerFoundException e) |
CodeResult |
handleRuntimeException(RuntimeException e) |
CodeResult |
handleSecurityException(SecurityException e) |
@ExceptionHandler(value=java.lang.IllegalArgumentException.class) public CodeResult handleIllegalArgumentException(IllegalArgumentException e)
@ExceptionHandler(value=java.lang.SecurityException.class) public CodeResult handleSecurityException(SecurityException e)
@ExceptionHandler(value=java.lang.NullPointerException.class) public CodeResult handleNullPointerException(NullPointerException e)
@ExceptionHandler(value=org.springframework.web.servlet.NoHandlerFoundException.class) public CodeResult handlerNoFoundException(org.springframework.web.servlet.NoHandlerFoundException e)
@ExceptionHandler(value=org.springframework.web.HttpMediaTypeNotSupportedException.class) public CodeResult handlerHttpMediaTypeNotSupportedException(org.springframework.web.HttpMediaTypeNotSupportedException e)
@ExceptionHandler(value=CodeException.class) public CodeResult handleCodeException(CodeException e)
@ExceptionHandler(value=java.lang.RuntimeException.class) public CodeResult handleRuntimeException(RuntimeException e)
@ExceptionHandler(value=java.lang.Exception.class) public CodeResult handleException(Exception e)
Copyright © 2022. All rights reserved.