@ControllerAdvice public class GlobalDefaultExceptionHandler extends Object
Constructor and Description |
---|
GlobalDefaultExceptionHandler() |
Modifier and Type | Method and Description |
---|---|
static String |
getErrorMsg(String id) |
void |
paramExceptionHandler(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
Exception e)
声明要捕获的异常
|
@ExceptionHandler(value={AgentException.class,AuthorizeException.class,java.lang.RuntimeException.class,java.lang.Exception.class}) public void paramExceptionHandler(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, Exception e)
Copyright © 2017–2019. All rights reserved.