程序包 cn.taketoday.web

类 HttpMediaTypeNotAcceptableException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
cn.taketoday.core.NestedRuntimeException
cn.taketoday.web.HttpMediaTypeException
cn.taketoday.web.HttpMediaTypeNotAcceptableException
所有已实现的接口:
HttpStatusCodeProvider, ErrorResponse, Serializable

public class HttpMediaTypeNotAcceptableException extends HttpMediaTypeException
Exception thrown when the request handler cannot generate a response that is acceptable by the client.
从以下版本开始:
4.0 2022/1/22 20:15
作者:
Arjen Poutsma, Harry Yang
另请参阅:
  • 构造器详细资料

    • HttpMediaTypeNotAcceptableException

      public HttpMediaTypeNotAcceptableException(String message)
      Constructor for when the Accept header cannot be parsed.
      参数:
      message - the parse error message
    • HttpMediaTypeNotAcceptableException

      public HttpMediaTypeNotAcceptableException(List<MediaType> mediaTypes)
      Create a new HttpMediaTypeNotSupportedException.
      参数:
      mediaTypes - the list of supported media types
  • 方法详细资料

    • getStatusCode

      public HttpStatus getStatusCode()
      从接口复制的说明: ErrorResponse
      Return the HTTP status code to use for the response.
    • getHeaders

      public HttpHeaders getHeaders()
      从接口复制的说明: ErrorResponse
      Return headers to use for the response.