Class InvalidMediaTypeException

All Implemented Interfaces:
Serializable

public class InvalidMediaTypeException extends IllegalArgumentException
Exception thrown from MediaType.parseMediaType(String) in case of encountering an invalid media type specification String.
Since:
3.2.2
Author:
Juergen Hoeller
See Also:
  • Constructor Details

    • InvalidMediaTypeException

      public InvalidMediaTypeException(String mediaType, String message)
      Create a new InvalidMediaTypeException for the given media type.
      Parameters:
      mediaType - the offending media type
      message - a detail message indicating the invalid part
  • Method Details

    • getMediaType

      public String getMediaType()
      Return the offending media type.