Using MIME_Type you can get different data about a MIME type. All methods mentioned here can be called statically.
getMedia() returns the main part (media part, portion
before the slash) of a MIME type. It would return image
for image/png
.
getSubType() returns the subtype of the given type.
For image/png
, it returns png
.
isExperimental() checks if a given MIME type is
experimental. It returns true
or
false
(e.g. text/x-vcard
).
isVendor() determines if the given type is a vendor
specific MIME type
(e.g. as in application/vnd.mozilla.xul+xml
).
isWildcard() tells you if the passed type is
a wildcard type (is either */*
or
something/*
).