Function

GLib-2.0GLiburi_parse_schemeSince 2.16

  • Gets the scheme portion of a URI string. RFC 3986 decodes the scheme as:

    URI = scheme ":" hier-part [ "?" query ] [ "#" fragment ]
    

    Common schemes include file, https, svn+ssh, etc.

    Parameters

    • uri: string

      a valid URI.

    Returns string

    The ‘scheme’ component of the URI, or null on error. The returned string should be freed when no longer needed.

    2.16