Created
January 23, 2020 20:34
-
-
Save vinniefalco/8055ab496456777c35a4c28a41223a57 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** Set the port. | |
The port of the URL is set to the specified | |
which must have the <em>port</em> syntax: | |
@li If the string is empty, the port is | |
cleared including the leading colon (':'). If | |
the port was the last remaining portion of | |
the authority, then the entire authority is | |
removed including the leading double slash ('//'). | |
Otherwise, | |
@li If the string is not empty then the port | |
is set to the given string, with a leading | |
colon added. | |
If the URL previously did not contain an | |
authority (@ref has_authority returns `false`), | |
then the authority is added including the | |
leading double slash ('//'). | |
The string must meet the syntactic requirements | |
of <em>port</em> otherwise an exception is | |
thrown. | |
@par ABNF | |
@code | |
port = *DIGIT | |
@endcode | |
@par Exception Safety | |
Strong guarantee. | |
Calls to allocate may throw. | |
@param s The string to set. | |
*/ | |
BOOST_URL_DECL | |
basic_value& | |
set_port(string_view s); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment