67,512
社区成员
发帖
与我相关
我的任务
分享
<context:component-scan base-package="com.pyp"></context:component-scan>
@ControllerAdvice
public class TestException {
@ExceptionHandler({ArithmeticException.class})
public ModelAndView testHandlerException(Exception error){
ModelAndView model =new ModelAndView("error");
model.addObject("exception", error);
return model;
}
}