Package rife.cmf

Class MimeType


public class MimeType extends EnumClass<String>
This is a typed enumeration of all the mime types that the content management framework specifically knows about.

The types that are defined here can be validated and transformed.

Since:
1.0
  • Field Details

    • APPLICATION_XHTML_IDENTIFIER

      public static final String APPLICATION_XHTML_IDENTIFIER
      See Also:
    • IMAGE_GIF_IDENTIFIER

      public static final String IMAGE_GIF_IDENTIFIER
      See Also:
    • IMAGE_JPEG_IDENTIFIER

      public static final String IMAGE_JPEG_IDENTIFIER
      See Also:
    • IMAGE_PNG_IDENTIFIER

      public static final String IMAGE_PNG_IDENTIFIER
      See Also:
    • TEXT_PLAIN_IDENTIFIER

      public static final String TEXT_PLAIN_IDENTIFIER
      See Also:
    • TEXT_XML_IDENTIFIER

      public static final String TEXT_XML_IDENTIFIER
      See Also:
    • RAW_IDENTIFIER

      public static final String RAW_IDENTIFIER
      See Also:
    • APPLICATION_XHTML

      public static final MimeType APPLICATION_XHTML
      The application/xhtml+xml mime type.
    • IMAGE_GIF

      public static final MimeType IMAGE_GIF
      The image/gif mime type.
    • IMAGE_JPEG

      public static final MimeType IMAGE_JPEG
      The image/jpeg mime type.
    • IMAGE_PNG

      public static final MimeType IMAGE_PNG
      The image/png mime type.
    • TEXT_PLAIN

      public static final MimeType TEXT_PLAIN
      The text/plain mime type.
    • TEXT_XML

      public static final MimeType TEXT_XML
      The text/plain mime type.
    • RAW

      public static final MimeType RAW
      A generic mime type indicating that the content should be stored as raw data without any mime-type related processing.
  • Method Details

    • getMimeType

      public static MimeType getMimeType(String identifier)
      Returns the MimeType instance that corresponds to a given textual identifier.
      Parameters:
      identifier - the identifier of the mime type that has to be retrieved
      Returns:
      the requested MimeType; or

      null if the MimeType is not supported

      Since:
      1.0