This module provides utility functions for working with URIs, according to RFC 3986.
Type definitions that are used more than once in this module:
boolean() = true | false
string() = list of ASCII characters
Type definitions that are related to URI:
- uri() = string()
Syntax according to the URI definition in RFC 3986, for example, "http://www.erlang.org/"
- user_info() = string()
- scheme() = atom()
Example: http, https
- host() = string()
- port() = pos_integer()
- path() = string()
Represents a file path or directory path
- query() = string()
- fragment() = string()
For more information about URI, see RFC 3986.
Decodes a possibly hexadecimal encoded URI.
Parses a URI. If no scheme defaults are provided, the value of the scheme_defaults function is used.
When parsing a URI with an unknown scheme (that is, a scheme not found in the scheme defaults), a port number must be provided, otherwise the parsing fails.
If the fragment option is true, the URI fragment is returned as part of the parsing result, otherwise it is ignored.