Class MediaType

  • public class MediaType
    extends Object
    • Method Detail

      • getType

        public String getType()
      • getSubtype

        public String getSubtype()
      • getCharset

        public String getCharset()
      • getParameterCount

        public int getParameterCount()
      • getParameterValue

        public String getParameterValue​(String parameter)
      • toStringNoCharset

        public String toStringNoCharset()
      • parseMediaType

        public static MediaType parseMediaType​(StringReader input)
                                        throws IOException
        Parses a MediaType value, either from an HTTP header or from an application.
        input - a reader over the header text
        a MediaType parsed from the input, or null if not valid
        IOException - if there was a problem reading the input