12345678module juptune.http.uri;
Result uriParseScheme(
const char[] chars,
const char[] scheme,
const char[] next,
UriParseHints hints
);
"Low level" Uri parsing functions
Parses the scheme of a URI.
Given the string "https://abc.com", the schemeparameter will be set to "https" and the nextparameter will be set to "//abc.com". The colon is dropped.
The output of all outparameters is undefined if the function returns an error.
The hint UriParseHints.isAbsoluteis always set.
UriError.schemeIsInvalidif the scheme does not start with an alpha character
UriError.schemeIsInvalidif the scheme is empty
UriError.schemeIsInvalidif the scheme contains an invalid character after the first
UriError.schemeIsInvalidif charsdoes not contain a ':' to terminate the scheme
A Resultindicating whether the parsing was successful or not.