クラス DefaultHandlerExceptionResolver

java.lang.ObjectSE
org.springframework.web.servlet.handler.AbstractHandlerExceptionResolver
org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolver
実装されたすべてのインターフェース:
OrderedHandlerExceptionResolver

public class DefaultHandlerExceptionResolver extends AbstractHandlerExceptionResolver
標準の Spring MVC 例外を解決し、対応する HTTP ステータスコードに変換する、HandlerExceptionResolver インターフェースのデフォルトの実装。

この例外リゾルバーは、一般的な Spring DispatcherServlet でデフォルトで有効になっています。

サポートされる例外
例外 HTTP ステータスコード

HttpRequestMethodNotSupportedException

405 (SC_METHOD_NOT_ALLOWED)

HttpMediaTypeNotSupportedException

415 (SC_UNSUPPORTED_MEDIA_TYPE)

HttpMediaTypeNotAcceptableException

406 (SC_NOT_ACCEPTABLE)

MissingPathVariableException

500 (SC_INTERNAL_SERVER_ERROR)

MissingServletRequestParameterException

400 (SC_BAD_REQUEST)

MissingServletRequestPartException

400 (SC_BAD_REQUEST)

ServletRequestBindingException

400 (SC_BAD_REQUEST)

ConversionNotSupportedException

500 (SC_INTERNAL_SERVER_ERROR)

TypeMismatchException

400 (SC_BAD_REQUEST)

HttpMessageNotReadableException

400 (SC_BAD_REQUEST)

HttpMessageNotWritableException

500 (SC_INTERNAL_SERVER_ERROR)

MethodArgumentNotValidException

400 (SC_BAD_REQUEST)

BindException

400 (SC_BAD_REQUEST)

NoHandlerFoundException

404 (SC_NOT_FOUND)

AsyncRequestTimeoutException

503 (SC_SERVICE_UNAVAILABLE)

導入:
3.0
作成者:
Arjen Poutsma, Rossen Stoyanchev, Juergen Hoeller
関連事項: