Was this page helpful?

TryParse Method

    TryParse(string contentTypeWithParameters, out MimeType result)

    public static bool TryParse(string contentTypeWithParameters, out MimeType result);
    Try to parse a mime-type from a content-type string.

    Parameters

    Name Type Description
    contentTypeWithParameters string Content type string.
    result out MimeType Mime-type instance return value.

    Returns

    Type: bool
    True if a mime-type could be parsed.

    TryParse(string contentTypeWithParameters, out string type, out string subtype, out Dictionary<string,string> parameters)

    protected static bool TryParse(string contentTypeWithParameters, out string type, out string subtype, out Dictionary<string,string> parameters);
    Try to parse a mime-type components from a content-type string.

    Parameters

    Name Type Description
    contentTypeWithParameters string Content type string.
    type out string Main type return value.
    subtype out string Sub-type return value.
    parameters out Dictionary<string,string> Dictionary of mime-type parameters.

    Returns

    Type: bool
    Was this page helpful?
    Tag page
    You must login to post a comment.

    Copyright © 2011 MindTouch, Inc. Powered by