public class InvalidMediaTypeException
extends java.lang.IllegalArgumentException
MediaType.parseMediaType(String)
in case of
encountering an invalid media type specification String.Modifier and Type | Field and Description |
---|---|
private java.lang.String |
mediaType |
Constructor and Description |
---|
InvalidMediaTypeException(InvalidMimeTypeException ex)
Constructor that allows wrapping
InvalidMimeTypeException . |
InvalidMediaTypeException(java.lang.String mediaType,
java.lang.String message)
Create a new InvalidMediaTypeException for the given media type.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getMediaType()
Return the offending media type.
|
public InvalidMediaTypeException(java.lang.String mediaType, java.lang.String message)
mediaType
- the offending media typemessage
- a detail message indicating the invalid partInvalidMediaTypeException(InvalidMimeTypeException ex)
InvalidMimeTypeException
.