public class HttpMediaTypeNotSupportedException extends HttpMediaTypeException
Modifier and Type | Field and Description |
---|---|
private MediaType |
contentType |
Constructor and Description |
---|
HttpMediaTypeNotSupportedException(MediaType contentType,
java.util.List<MediaType> supportedMediaTypes)
Create a new HttpMediaTypeNotSupportedException.
|
HttpMediaTypeNotSupportedException(MediaType contentType,
java.util.List<MediaType> supportedMediaTypes,
java.lang.String msg)
Create a new HttpMediaTypeNotSupportedException.
|
HttpMediaTypeNotSupportedException(java.lang.String message)
Create a new HttpMediaTypeNotSupportedException.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
getContentType()
Return the HTTP request content type method that caused the failure.
|
getSupportedMediaTypes
private final MediaType contentType
public HttpMediaTypeNotSupportedException(java.lang.String message)
message
- the exception messagepublic HttpMediaTypeNotSupportedException(MediaType contentType, java.util.List<MediaType> supportedMediaTypes)
contentType
- the unsupported content typesupportedMediaTypes
- the list of supported media typespublic HttpMediaTypeNotSupportedException(MediaType contentType, java.util.List<MediaType> supportedMediaTypes, java.lang.String msg)
contentType
- the unsupported content typesupportedMediaTypes
- the list of supported media typesmsg
- the detail messagepublic MediaType getContentType()