Package 

Class MediaType

  • All Implemented Interfaces:
    android.os.Parcelable

    
    public final class MediaType
     implements Parcelable
                        

    Represents a document format, identified by a unique RFC 6838 media type.

    MediaType handles:

    • components parsing – eg. type, subtype and parameters,

    • media types comparison.

    Comparing media types is more complicated than it looks, since they can contain parameters, such as charset=utf-8. We can't ignore them because some formats use parameters in their media type, for example application/atom+xml;profile=opds-catalog for an OPDS 1 catalog.

    Specification: https://tools.ietf.org/html/rfc6838