LocAdviceErrorAutoConfiguration.java 文件源码

java
阅读 17 收藏 0 点赞 0 评论 0

项目:loc-framework 作者:
@ResponseStatus(value = HttpStatus.METHOD_NOT_ALLOWED)
@ExceptionHandler(HttpRequestMethodNotSupportedException.class)
//对于接口方法不匹配的异常处理
public BasicResult handleHttpRequestMethodNotSupportedException(
    HttpRequestMethodNotSupportedException e) {
  logError("httpRequestMethodNotSupportedException", e.getMessage(), e);
  return BasicResult
      .fail(BasicResultCode.METHOD_NOT_ALLOW_ERROR.getCode(),
          BasicResultCode.METHOD_NOT_ALLOW_ERROR.getMsg(),
          e.getMessage());
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号