Added support for returning the parsed MIME type. This is useful when the caller needs to perform different logic based on the MIME type.