Class ContentType


  • @ProviderType
    public final class ContentType
    extends java.lang.Object
    Frequently used content types/mime types. All mime types that that require encoding definition include UTF-8 as charset.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String CSS
      CSS with UTF-8
      static java.lang.String CSV
      CSV (no charset included in mime type because charset can differ from platform to platform)
      static java.lang.String DOWNLOAD
      MIME type used for items that should initiate a "save-as" dialog in the browser.
      static java.lang.String GIF
      GIF image
      static java.lang.String HTML
      HTML with UTF-8
      static java.lang.String JAVASCRIPT
      JavaScript with UTF-8
      static java.lang.String JPEG
      JPEG image
      static java.lang.String JSON
      JSON with UTF-8
      static java.lang.String OCTET_STREAM
      Default binary content type
      static java.lang.String PDF
      PDF
      static java.lang.String PLAINTEXT
      Plain text with UTF-8
      static java.lang.String PNG
      PNG image
      static java.lang.String SVG
      SVG
      static java.lang.String SWF
      Flash file
      static java.lang.String TIFF
      TIFF
      static java.lang.String WEBP
      WebP
      static java.lang.String XHTML
      XHTML (no charset, charset is defined within XML markup)
      static java.lang.String XML
      XML (no charset, charset is defined within XML markup)
      static java.lang.String ZIP
      ZIP
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • HTML

        public static final java.lang.String HTML
        HTML with UTF-8
      • JSON

        public static final java.lang.String JSON
        JSON with UTF-8
      • PLAINTEXT

        public static final java.lang.String PLAINTEXT
        Plain text with UTF-8
      • CSS

        public static final java.lang.String CSS
        CSS with UTF-8
      • JAVASCRIPT

        public static final java.lang.String JAVASCRIPT
        JavaScript with UTF-8
      • XML

        public static final java.lang.String XML
        XML (no charset, charset is defined within XML markup)
        See Also:
        Constant Field Values
      • XHTML

        public static final java.lang.String XHTML
        XHTML (no charset, charset is defined within XML markup)
        See Also:
        Constant Field Values
      • OCTET_STREAM

        public static final java.lang.String OCTET_STREAM
        Default binary content type
        See Also:
        Constant Field Values
      • DOWNLOAD

        public static final java.lang.String DOWNLOAD
        MIME type used for items that should initiate a "save-as" dialog in the browser. (This is a non-standard MIME type by design to make sure the browser does not do anything with it).
        See Also:
        Constant Field Values
      • CSV

        public static final java.lang.String CSV
        CSV (no charset included in mime type because charset can differ from platform to platform)
        See Also:
        Constant Field Values