= Reference
:mrdocs:

[#index]

= Global namespace

== Namespaces
[,cols=2]
|===
|Name |Description
|xref:boost[`pass:v[boost]`] |

|xref:std[`pass:v[std]`] |

|===

[#boost]

= Namespace boost

== Namespaces
[,cols=2]
|===
|Name |Description
|xref:boost-system[`pass:v[system]`] |

|xref:boost-urls[`pass:v[urls]`] |

|===

[#boost-urls]

= Namespace urls

== Namespaces
[,cols=2]
|===
|Name |Description
|xref:boost-urls-error_types[`pass:v[error_types]`] |

|xref:boost-urls-grammar[`pass:v[grammar]`] |

|xref:boost-urls-string_token[`pass:v[string_token]`] |

|===
==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-absolute_uri_rule_t[`pass:v[absolute_uri_rule_t]`] |

|xref:boost-urls-authority_rule_t[`pass:v[authority_rule_t]`] |

|xref:boost-urls-authority_view[`pass:v[authority_view]`] |
pass:v,q[A non-owning reference to a valid authority]

|xref:boost-urls-decode_view[`pass:v[decode_view]`] |
pass:v,q[A reference to a valid, percent-encoded string]

|xref:boost-urls-encoding_opts[`pass:v[encoding_opts]`] |
pass:v,q[Percent-encoding options]

|xref:boost-urls-ignore_case_param[`pass:v[ignore_case_param]`] |
pass:v,q[An optional parameter to determine case-sensitivity]

|xref:boost-urls-ignore_case_t[`pass:v[ignore_case_t]`] |

|xref:boost-urls-ipv4_address[`pass:v[ipv4_address]`] |
pass:v,q[An IP version 4 style address.]

|xref:boost-urls-ipv4_address_rule_t[`pass:v[ipv4_address_rule_t]`] |

|xref:boost-urls-ipv6_address[`pass:v[ipv6_address]`] |
pass:v,q[An IP version 6 style address.]

|xref:boost-urls-ipv6_address_rule_t[`pass:v[ipv6_address_rule_t]`] |

|xref:boost-urls-make_void[`pass:v[make_void]`] |

|xref:boost-urls-no_value_t[`pass:v[no_value_t]`] |
pass:v,q[The type of no_value]

|xref:boost-urls-optional[`pass:v[optional]`] |

|xref:boost-urls-origin_form_rule_t[`pass:v[origin_form_rule_t]`] |

|xref:boost-urls-param[`pass:v[param]`] |
pass:v,q[A query parameter]

|xref:boost-urls-param_pct_view[`pass:v[param_pct_view]`] |
pass:v,q[A query parameter]

|xref:boost-urls-param_view[`pass:v[param_view]`] |
pass:v,q[A query parameter]

|xref:boost-urls-params_base[`pass:v[params_base]`] |
pass:v,q[Common functionality for containers]

|xref:boost-urls-params_encoded_base[`pass:v[params_encoded_base]`] |
pass:v,q[Common functionality for containers]

|xref:boost-urls-params_encoded_ref[`pass:v[params_encoded_ref]`] |
pass:v,q[A view representing query parameters in a URL]

|xref:boost-urls-params_encoded_view[`pass:v[params_encoded_view]`] |
pass:v,q[A view representing query parameters in a URL]

|xref:boost-urls-params_ref[`pass:v[params_ref]`] |
pass:v,q[A view representing query parameters in a URL]

|xref:boost-urls-params_view[`pass:v[params_view]`] |
pass:v,q[A view representing query parameters in a URL]

|xref:boost-urls-pct_encoded_rule_t[`pass:v[pct_encoded_rule_t]`] |

|xref:boost-urls-pct_string_view[`pass:v[pct_string_view]`] |
pass:v,q[A reference to a valid percent-encoded string]

|xref:boost-urls-query_rule_t[`pass:v[query_rule_t]`] |

|xref:boost-urls-relative_ref_rule_t[`pass:v[relative_ref_rule_t]`] |

|xref:boost-urls-segments_base[`pass:v[segments_base]`] |
pass:v,q[Common functionality for containers]

|xref:boost-urls-segments_encoded_base[`pass:v[segments_encoded_base]`] |
pass:v,q[Common functionality for containers]

|xref:boost-urls-segments_encoded_ref[`pass:v[segments_encoded_ref]`] |
pass:v,q[A view representing path segments in a URL]

|xref:boost-urls-segments_encoded_view[`pass:v[segments_encoded_view]`] |
pass:v,q[A view representing path segments in a URL]

|xref:boost-urls-segments_ref[`pass:v[segments_ref]`] |
pass:v,q[A view representing path segments in a URL]

|xref:boost-urls-segments_view[`pass:v[segments_view]`] |
pass:v,q[A view representing path segments in a URL]

|xref:boost-urls-static_url[`pass:v[static_url]`] |
pass:v,q[A modifiable container for a URL.]

|xref:boost-urls-static_url_base[`pass:v[static_url_base]`] |
pass:v,q[Common implementation for all static URLs]

|xref:boost-urls-uri_reference_rule_t[`pass:v[uri_reference_rule_t]`] |

|xref:boost-urls-uri_rule_t[`pass:v[uri_rule_t]`] |

|xref:boost-urls-url[`pass:v[url]`] |
pass:v,q[A modifiable container for a URL.]

|xref:boost-urls-url_base[`pass:v[url_base]`] |
pass:v,q[Common functionality for containers]

|xref:boost-urls-url_view[`pass:v[url_view]`] |
pass:v,q[A non-owning reference to a valid URL]

|xref:boost-urls-url_view_base[`pass:v[url_view_base]`] |
pass:v,q[Common functionality for containers]

|xref:boost-urls-variant[`pass:v[variant]`] |
pass:v,q[The type of variant used by the library]

|xref:boost-urls-void_t[`pass:v[void_t]`] |

|===
==  Enums
[,cols=2]
|===
|Name |Description
|xref:boost-urls-error[`pass:v[error]`] |
pass:v,q[Error codes returned the library]

|xref:boost-urls-host_type[`pass:v[host_type]`] |
pass:v,q[Identifies the type of host in a URL.]

|xref:boost-urls-scheme[`pass:v[scheme]`] |
pass:v,q[Identifies a known URL scheme]

|===
== Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-default_port[`pass:v[default_port]`] |
pass:v,q[Return the default port for a known scheme]

|xref:boost-urls-encode[`pass:v[encode]`] |
pass:v,q[Apply percent-encoding to a string]

pass:v,q[Return a percent-encoded string]

|xref:boost-urls-encode_unsafe[`pass:v[encode_unsafe]`] |

|xref:boost-urls-encoded_size[`pass:v[encoded_size]`] |
pass:v,q[Return the buffer size needed for percent-encoding]

|xref:boost-urls-make_error_code[`pass:v[make_error_code]`] |

|xref:boost-urls-make_pct_string_view[`pass:v[make_pct_string_view]`] |
pass:v,q[Return a valid percent-encoded string]

|xref:boost-urls-make_pct_string_view_unsafe[`pass:v[make_pct_string_view_unsafe]`] |

|xref:boost-urls-operator_not_eq[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two URLs]

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

pass:v,q[Return true if two addresses are not equal]

|xref:boost-urls-operator_lt[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two URLs]

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-operator_lshift[`pass:v[operator<<]`] |
pass:v,q[Format the address to an output stream.]

pass:v,q[Format the address to an output stream]

pass:v,q[Format the encoded authority to the output stream]

pass:v,q[Format the string with percent-decoding applied to the output stream]

pass:v,q[Format the url to the output stream]

pass:v,q[Format to an output stream]

|xref:boost-urls-operator_le[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two URLs]

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-operator_eq[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two URLs]

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

pass:v,q[Return true if two addresses are equal]

|xref:boost-urls-operator_gt[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two URLs]

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-operator_ge[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two URLs]

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-parse_absolute_uri[`pass:v[parse_absolute_uri]`] |
pass:v,q[Return a reference to a parsed URL string]

|xref:boost-urls-parse_authority[`pass:v[parse_authority]`] |
pass:v,q[Parse an authority]

|xref:boost-urls-parse_ipv4_address[`pass:v[parse_ipv4_address]`] |
pass:v,q[Return an IPv4 address from an IP address string in dotted decimal form]

|xref:boost-urls-parse_ipv6_address[`pass:v[parse_ipv6_address]`] |
pass:v,q[Parse a string containing an IPv6 address.]

|xref:boost-urls-parse_origin_form[`pass:v[parse_origin_form]`] |
pass:v,q[Return a reference to a parsed URL string]

|xref:boost-urls-parse_path[`pass:v[parse_path]`] |
pass:v,q[Parse a string and return an encoded segment view]

|xref:boost-urls-parse_query[`pass:v[parse_query]`] |
pass:v,q[Parse a string and return an encoded params view]

|xref:boost-urls-parse_relative_ref[`pass:v[parse_relative_ref]`] |
pass:v,q[Return a reference to a parsed URL string]

|xref:boost-urls-parse_uri[`pass:v[parse_uri]`] |
pass:v,q[Return a reference to a parsed URL string]

|xref:boost-urls-parse_uri_reference[`pass:v[parse_uri_reference]`] |
pass:v,q[Return a reference to a parsed URL string]

|xref:boost-urls-pct_encoded_rule[`pass:v[pct_encoded_rule]`] |
|xref:boost-urls-resolve[`pass:v[resolve]`] |
pass:v,q[Resolve a URL reference against a base URL]

|xref:boost-urls-string_to_scheme[`pass:v[string_to_scheme]`] |
pass:v,q[Return the known scheme for a non-normalized string, if known]

|xref:boost-urls-swap[`pass:v[swap]`] |
pass:v,q[Swap]

|xref:boost-urls-to_string[`pass:v[to_string]`] |
pass:v,q[Return the normalized string for a known scheme]

|===
== Variables
[,cols=2]
|===
|Name |Description
|xref:boost-urls-absolute_uri_rule[`pass:v[absolute_uri_rule]`] |

|xref:boost-urls-authority_rule[`pass:v[authority_rule]`] |

|xref:boost-urls-ignore_case[`pass:v[ignore_case]`] |

|xref:boost-urls-ipv4_address_rule[`pass:v[ipv4_address_rule]`] |

|xref:boost-urls-ipv6_address_rule[`pass:v[ipv6_address_rule]`] |

|xref:boost-urls-no_value[`pass:v[no_value]`] |
pass:v,q[Constant indicating no value in a param]

|xref:boost-urls-origin_form_rule[`pass:v[origin_form_rule]`] |

|xref:boost-urls-pchars[`pass:v[pchars]`] |
pass:v,q[The path character set]

|xref:boost-urls-query_rule[`pass:v[query_rule]`] |

|xref:boost-urls-relative_ref_rule[`pass:v[relative_ref_rule]`] |

|xref:boost-urls-sub_delim_chars[`pass:v[sub_delim_chars]`] |
pass:v,q[The sub-delims character set]

|xref:boost-urls-unreserved_chars[`pass:v[unreserved_chars]`] |
pass:v,q[The unreserved character set]

|xref:boost-urls-uri_reference_rule[`pass:v[uri_reference_rule]`] |

|xref:boost-urls-uri_rule[`pass:v[uri_rule]`] |

|===

[#boost-urls-make_void]

= Class make_void



== Synopsis

Declared in header `</boost/url/detail/config.hpp#L138[boost/url/detail/config.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class...>
struct make_void;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-make_void-type[`pass:v[type]`] |

|===



[#boost-urls-make_void-type]

= make_void::type



== Synopsis

Declared in header `</boost/url/detail/config.hpp#L138[boost/url/detail/config.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef void type;
----


[#boost-urls-void_t]

= void_t



== Synopsis

Declared in header `</boost/url/detail/config.hpp#L139[boost/url/detail/config.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class... Ts>
using void_t = xref:boost-urls-make_void[make_void]<Ts...>::type;
----


[#boost-urls-grammar]

= Namespace grammar

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-aligned_storage[`pass:v[aligned_storage]`] |

|xref:boost-urls-grammar-all_chars_t[`pass:v[all_chars_t]`] |

|xref:boost-urls-grammar-alnum_chars_t[`pass:v[alnum_chars_t]`] |

|xref:boost-urls-grammar-alpha_chars_t[`pass:v[alpha_chars_t]`] |

|xref:boost-urls-grammar-ch_delim_rule[`pass:v[ch_delim_rule]`] |

|xref:boost-urls-grammar-ci_equal[`pass:v[ci_equal]`] |

|xref:boost-urls-grammar-ci_hash[`pass:v[ci_hash]`] |

|xref:boost-urls-grammar-ci_less[`pass:v[ci_less]`] |

|xref:boost-urls-grammar-cs_delim_rule[`pass:v[cs_delim_rule]`] |

|xref:boost-urls-grammar-dec_octet_rule_t[`pass:v[dec_octet_rule_t]`] |

|xref:boost-urls-grammar-digit_chars_t[`pass:v[digit_chars_t]`] |

|xref:boost-urls-grammar-hexdig_chars_t[`pass:v[hexdig_chars_t]`] |

|xref:boost-urls-grammar-is_charset-06[`pass:v[is_charset]`] |

|xref:boost-urls-grammar-is_charset-0c[`pass:v[is_charset<T, void_t<decltype(std::declval<bool&>() =
                std::declval<T const&>().operator()(
                    std::declval<char>()))>>]`] |

|xref:boost-urls-grammar-is_rule-0a[`pass:v[is_rule]`] |

|xref:boost-urls-grammar-is_rule-0f[`pass:v[is_rule<T, void_t<decltype(std::declval<system::result<typename T::value_type>&>() =
                std::declval<T const&>().parse(
                    std::declval<char const*&>(),
                    std::declval<char const*>()))>>]`] |

|xref:boost-urls-grammar-literal_rule[`pass:v[literal_rule]`] |

|xref:boost-urls-grammar-lut_chars[`pass:v[lut_chars]`] |
pass:v,q[A set of characters]

|xref:boost-urls-grammar-optional_rule_t[`pass:v[optional_rule_t]`] |

|xref:boost-urls-grammar-range[`pass:v[range]`] |
pass:v,q[A forward range of parsed elements]

|xref:boost-urls-grammar-range_rule_t-09[`pass:v[range_rule_t]`] |

|xref:boost-urls-grammar-range_rule_t-01[`pass:v[range_rule_t<R>]`] |

|xref:boost-urls-grammar-recycled[`pass:v[recycled]`] |
pass:v,q[A thread-safe collection of instances of T]

|xref:boost-urls-grammar-recycled_ptr[`pass:v[recycled_ptr]`] |
pass:v,q[A pointer to shared instance of T]

|xref:boost-urls-grammar-string_view_base[`pass:v[string_view_base]`] |
pass:v,q[Common functionality for string views]

|xref:boost-urls-grammar-token_rule_t[`pass:v[token_rule_t]`] |

|xref:boost-urls-grammar-tuple_rule_t[`pass:v[tuple_rule_t]`] |

|xref:boost-urls-grammar-unsigned_rule[`pass:v[unsigned_rule]`] |

|xref:boost-urls-grammar-variant_rule_t[`pass:v[variant_rule_t]`] |

|xref:boost-urls-grammar-vchars_t[`pass:v[vchars_t]`] |

|===
==  Enums
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-condition[`pass:v[condition]`] |
pass:v,q[Error conditions for errors received from rules]

|xref:boost-urls-grammar-error[`pass:v[error]`] |
pass:v,q[Error codes returned when using rules]

|===
== Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ci_compare[`pass:v[ci_compare]`] |
pass:v,q[Return the case-insensitive comparison of s0 and s1]

|xref:boost-urls-grammar-ci_digest[`pass:v[ci_digest]`] |
pass:v,q[Return the case-insensitive digest of a string]

|xref:boost-urls-grammar-ci_is_equal[`pass:v[ci_is_equal]`] |
|xref:boost-urls-grammar-ci_is_less[`pass:v[ci_is_less]`] |
pass:v,q[Return true if s0 is less than s1 using case-insensitive comparison]

|xref:boost-urls-grammar-delim_rule[`pass:v[delim_rule]`] |
|xref:boost-urls-grammar-find_if[`pass:v[find_if]`] |
pass:v,q[Find the first character in the string that is in the set.]

|xref:boost-urls-grammar-find_if_not[`pass:v[find_if_not]`] |
pass:v,q[Find the first character in the string that is not in CharSet]

|xref:boost-urls-grammar-hash_value[`pass:v[hash_value]`] |
pass:v,q[Return the hash of this value]

|xref:boost-urls-grammar-hexdig_value[`pass:v[hexdig_value]`] |
pass:v,q[Return the decimal value of a hex character]

|xref:boost-urls-grammar-make_error_code[`pass:v[make_error_code]`] |

|xref:boost-urls-grammar-make_error_condition[`pass:v[make_error_condition]`] |

|xref:boost-urls-grammar-operator_not_eq[`pass:v[operator!=]`] |

|xref:boost-urls-grammar-operator_plus[`pass:v[operator+]`] |
pass:v,q[Return the union of two character sets.]

|xref:boost-urls-grammar-operator_minus[`pass:v[operator-]`] |
pass:v,q[Return a new character set by subtracting]

|xref:boost-urls-grammar-operator_lt[`pass:v[operator<]`] |

|xref:boost-urls-grammar-operator_lshift[`pass:v[operator<<]`] |
pass:v,q[Format a string to an output stream]

|xref:boost-urls-grammar-operator_le[`pass:v[operator<=]`] |

|xref:boost-urls-grammar-operator_eq[`pass:v[operator==]`] |

|xref:boost-urls-grammar-operator_gt[`pass:v[operator>]`] |

|xref:boost-urls-grammar-operator_ge[`pass:v[operator>=]`] |

|xref:boost-urls-grammar-optional_rule[`pass:v[optional_rule]`] |
|xref:boost-urls-grammar-parse[`pass:v[parse]`] |
pass:v,q[Parse a character buffer using a rule]

|xref:boost-urls-grammar-range_rule[`pass:v[range_rule]`] |
|xref:boost-urls-grammar-ref[`pass:v[ref]`] |
|xref:boost-urls-grammar-squelch[`pass:v[squelch]`] |

|xref:boost-urls-grammar-to_lower[`pass:v[to_lower]`] |
pass:v,q[Return c converted to lowercase]

|xref:boost-urls-grammar-to_upper[`pass:v[to_upper]`] |
pass:v,q[Return c converted to uppercase]

|xref:boost-urls-grammar-token_rule[`pass:v[token_rule]`] |

|xref:boost-urls-grammar-tuple_rule[`pass:v[tuple_rule]`] |
|xref:boost-urls-grammar-variant_rule[`pass:v[variant_rule]`] |
|===
== Variables
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-all_chars[`pass:v[all_chars]`] |
pass:v,q[A character set containing all characters.]

|xref:boost-urls-grammar-alnum_chars[`pass:v[alnum_chars]`] |

|xref:boost-urls-grammar-alpha_chars[`pass:v[alpha_chars]`] |
pass:v,q[A character set containing the alphabetical characters.]

|xref:boost-urls-grammar-dec_octet_rule[`pass:v[dec_octet_rule]`] |

|xref:boost-urls-grammar-digit_chars[`pass:v[digit_chars]`] |

|xref:boost-urls-grammar-hexdig_chars[`pass:v[hexdig_chars]`] |

|xref:boost-urls-grammar-vchars[`pass:v[vchars]`] |

|===

[#boost-urls-grammar-lut_chars]

= Class lut_chars

pass:v,q[A set of characters]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L64[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class lut_chars;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-lut_chars-find_if[`pass:v[find_if]`] |

|xref:boost-urls-grammar-lut_chars-find_if_not[`pass:v[find_if_not]`] |

|xref:boost-urls-grammar-lut_chars-2constructor[`pass:v[lut_chars]`] |
pass:v,q[Constructor]

|xref:boost-urls-grammar-lut_chars-operator_call[`pass:v[operator()]`] |
pass:v,q[Return true if ch is in the character set.]

|xref:boost-urls-grammar-lut_chars-operator_bitnot[`pass:v[operator~]`] |
pass:v,q[Return a new character set which is the complement of another character set.]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-lut_chars-8friend-02[`pass:v[operator+]`] |
pass:v,q[Return the union of two character sets.]

|xref:boost-urls-grammar-lut_chars-8friend-07[`pass:v[operator-]`] |
pass:v,q[Return a new character set by subtracting]

|===

== Description

pass:v,q[The characters defined by instances of] pass:v,q[this set are provided upon construction.]
pass:v,q[The `constexpr` implementation allows]
pass:v,q[these to become compile-time constants.]

=== Example
pass:v,q[Character sets are used with rules and the]
pass:v,q[functions]
xref:boost-urls-grammar-lut_chars-find_if[find_if]
pass:v,q[and]
xref:boost-urls-grammar-lut_chars-find_if_not[find_if_not.]
[,cpp]
----
constexpr lut_chars vowel_chars = "AEIOU" "aeiou";

system::result< core::string_view > rv = parse( "Aiea", token_rule( vowel_chars ) );
----




[#boost-urls-grammar-lut_chars-2constructor]

= Overload set lut_chars::lut_chars

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
lut_chars(char ch) noexcept;
  xref:boost-urls-grammar-lut_chars-2constructor-079[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
lut_chars(const char* s) noexcept;
  xref:boost-urls-grammar-lut_chars-2constructor-074[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class Pred,
    class = enable_if<detail::is_pred<Pred>::value && !std::is_base_of<lut_chars, Pred>::value>::type>
constexpr
lut_chars(const Pred& pred) noexcept;
  xref:boost-urls-grammar-lut_chars-2constructor-02[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-lut_chars-operator_call]

= Function lut_chars::operator()

pass:v,q[Return true if ch is in the character set.]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L256[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
operator()(unsigned char ch) const noexcept;
----

== Description

pass:v,q[This function returns true if the] pass:v,q[character `ch` is in the set, otherwise]
pass:v,q[it returns false.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *ch*
| `unsigned char`

|===




[#boost-urls-grammar-lut_chars-8friend-02]

= Friend operator+

pass:v,q[Return the union of two character sets.]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L291[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
constexpr
xref:boost-urls-grammar-lut_chars[lut_chars]
operator+(
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs0,
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs1) noexcept;
----

== Description

pass:v,q[This function returns a new character] pass:v,q[set which contains all of the characters]
pass:v,q[in `cs0` as well as all of the characters]
pass:v,q[in `cs`.]

=== Example
pass:v,q[This creates a character set which]
pass:v,q[includes all letters and numbers]
[,cpp]
----
constexpr lut_chars alpha_chars(
    "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
    "abcdefghijklmnopqrstuvwxyz");

constexpr lut_chars alnum_chars = alpha_chars + "0123456789";
----

=== Complexity
pass:v,q[Constant.]



[#boost-urls-grammar-lut_chars-8friend-07]

= Friend operator-

pass:v,q[Return a new character set by subtracting]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L328[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
constexpr
xref:boost-urls-grammar-lut_chars[lut_chars]
operator-(
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs0,
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs1) noexcept;
----

== Description

pass:v,q[This function returns a new character] pass:v,q[set which is formed from all of the]
pass:v,q[characters in `cs0` which are not in `cs`.]

=== Example
pass:v,q[This statement declares a character set]
pass:v,q[containing all the lowercase letters]
pass:v,q[which are not vowels:]
[,cpp]
----
constexpr lut_chars consonants = lut_chars("abcdefghijklmnopqrstuvwxyz") - "aeiou";
----

=== Complexity
pass:v,q[Constant.]



[#boost-urls-grammar-lut_chars-operator_bitnot]

= Function lut_chars::operator~

pass:v,q[Return a new character set which is the complement of another character set.]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L363[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-lut_chars[lut_chars]
operator~() const noexcept;
----

== Description

pass:v,q[This function returns a new character] pass:v,q[set which contains all of the characters]
pass:v,q[that are not in `*this`.]

=== Example
pass:v,q[This statement declares a character set]
pass:v,q[containing everything but vowels:]
[,cpp]
----
constexpr lut_chars not_vowels = ~lut_chars( "AEIOU" "aeiou" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `lut_chars` 





[#boost-urls-grammar-lut_chars-find_if]

= Function lut_chars::find_if



== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L377[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-lut_chars-find_if_not]

= Function lut_chars::find_if_not



== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L386[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if_not(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-operator_plus]

= Function operator+

pass:v,q[Return the union of two character sets.]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L291[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-lut_chars[lut_chars]
operator+(
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs0,
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs1) noexcept;
----

== Description

pass:v,q[This function returns a new character] pass:v,q[set which contains all of the characters]
pass:v,q[in `cs0` as well as all of the characters]
pass:v,q[in `cs`.]

=== Example
pass:v,q[This creates a character set which]
pass:v,q[includes all letters and numbers]
[,cpp]
----
constexpr lut_chars alpha_chars(
    "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
    "abcdefghijklmnopqrstuvwxyz");

constexpr lut_chars alnum_chars = alpha_chars + "0123456789";
----

=== Complexity
pass:v,q[Constant.]



== Return Value

* `lut_chars` 


== Parameters

|===
| Name | Type 

| *cs0*
| ``

| *cs1*
| ``

|===




[#boost-urls-grammar-operator_minus]

= Function operator-

pass:v,q[Return a new character set by subtracting]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L328[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-lut_chars[lut_chars]
operator-(
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs0,
    const xref:boost-urls-grammar-lut_chars[lut_chars]& cs1) noexcept;
----

== Description

pass:v,q[This function returns a new character] pass:v,q[set which is formed from all of the]
pass:v,q[characters in `cs0` which are not in `cs`.]

=== Example
pass:v,q[This statement declares a character set]
pass:v,q[containing all the lowercase letters]
pass:v,q[which are not vowels:]
[,cpp]
----
constexpr lut_chars consonants = lut_chars("abcdefghijklmnopqrstuvwxyz") - "aeiou";
----

=== Complexity
pass:v,q[Constant.]



== Return Value

* `lut_chars` 


== Parameters

|===
| Name | Type 

| *cs0*
| ``

| *cs1*
| ``

|===




[#boost-urls-grammar-string_view_base]

= Class string_view_base

pass:v,q[Common functionality for string views]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L36[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class string_view_base;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-const_iterator[`pass:v[const_iterator]`] |
pass:v,q[The const iterator type]

|xref:boost-urls-grammar-string_view_base-const_pointer[`pass:v[const_pointer]`] |
pass:v,q[The const pointer type]

|xref:boost-urls-grammar-string_view_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The const reference type]

|xref:boost-urls-grammar-string_view_base-const_reverse_iterator[`pass:v[const_reverse_iterator]`] |
pass:v,q[The const reverse iterator type]

|xref:boost-urls-grammar-string_view_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[The difference type]

|xref:boost-urls-grammar-string_view_base-iterator[`pass:v[iterator]`] |
pass:v,q[The iterator type]

|xref:boost-urls-grammar-string_view_base-pointer[`pass:v[pointer]`] |
pass:v,q[The pointer type]

|xref:boost-urls-grammar-string_view_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-grammar-string_view_base-reverse_iterator[`pass:v[reverse_iterator]`] |
pass:v,q[The reverse iterator type]

|xref:boost-urls-grammar-string_view_base-size_type[`pass:v[size_type]`] |
pass:v,q[The size type]

|xref:boost-urls-grammar-string_view_base-traits_type[`pass:v[traits_type]`] |
pass:v,q[The character traits]

|xref:boost-urls-grammar-string_view_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-at[`pass:v[at]`] |
pass:v,q[Access a character]

|xref:boost-urls-grammar-string_view_base-back[`pass:v[back]`] |
pass:v,q[Return the last character]

|xref:boost-urls-grammar-string_view_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-grammar-string_view_base-cbegin[`pass:v[cbegin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-grammar-string_view_base-cend[`pass:v[cend]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-grammar-string_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing to another string]

|xref:boost-urls-grammar-string_view_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if matching characters are found]

|xref:boost-urls-grammar-string_view_base-copy[`pass:v[copy]`] |
pass:v,q[Copy the characters to another buffer]

|xref:boost-urls-grammar-string_view_base-crbegin[`pass:v[crbegin]`] |

|xref:boost-urls-grammar-string_view_base-crend[`pass:v[crend]`] |

|xref:boost-urls-grammar-string_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the character buffer]

|xref:boost-urls-grammar-string_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the string is empty]

|xref:boost-urls-grammar-string_view_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-grammar-string_view_base-ends_with[`pass:v[ends_with]`] |
pass:v,q[Return true if a matching suffix exists]

|xref:boost-urls-grammar-string_view_base-find[`pass:v[find]`] |
pass:v,q[Return the position of matching characters]

|xref:boost-urls-grammar-string_view_base-find_first_not_of[`pass:v[find_first_not_of]`] |
pass:v,q[Return the position of the first non-match]

|xref:boost-urls-grammar-string_view_base-find_first_of[`pass:v[find_first_of]`] |
pass:v,q[Return the position of the first match]

|xref:boost-urls-grammar-string_view_base-find_last_not_of[`pass:v[find_last_not_of]`] |
pass:v,q[Return the position of the last non-match]

|xref:boost-urls-grammar-string_view_base-find_last_of[`pass:v[find_last_of]`] |
pass:v,q[Return the position of the last match]

|xref:boost-urls-grammar-string_view_base-front[`pass:v[front]`] |
pass:v,q[Return the first character]

|xref:boost-urls-grammar-string_view_base-length[`pass:v[length]`] |
pass:v,q[Return the size]

|xref:boost-urls-grammar-string_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum allowed size]

|xref:boost-urls-grammar-string_view_base-2conversion-06[`pass:v[operator string]`] |
pass:v,q[Conversion]

|xref:boost-urls-grammar-string_view_base-2conversion-0e[`pass:v[operator string_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-grammar-string_view_base-operator_subs[`pass:v[operator[]]`] |
pass:v,q[Access a character]

|xref:boost-urls-grammar-string_view_base-rbegin[`pass:v[rbegin]`] |

|xref:boost-urls-grammar-string_view_base-rend[`pass:v[rend]`] |

|xref:boost-urls-grammar-string_view_base-rfind[`pass:v[rfind]`] |
pass:v,q[Return the position of matching characters]

|xref:boost-urls-grammar-string_view_base-size[`pass:v[size]`] |
pass:v,q[Return the size]

|xref:boost-urls-grammar-string_view_base-starts_with[`pass:v[starts_with]`] |
pass:v,q[Return true if a matching prefix exists]

|xref:boost-urls-grammar-string_view_base-substr[`pass:v[substr]`] |
pass:v,q[Return a view to part of the string]

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-npos[`pass:v[npos]`] |
pass:v,q[A constant used to represent "no position"]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-8friend-09d[`pass:v[hash_value]`] |
pass:v,q[Return the hash of this value]

|xref:boost-urls-grammar-string_view_base-8friend-017[`pass:v[operator!=]`] |

|xref:boost-urls-grammar-string_view_base-8friend-010[`pass:v[operator<]`] |

|xref:boost-urls-grammar-string_view_base-8friend-00[`pass:v[operator<<]`] |

|xref:boost-urls-grammar-string_view_base-8friend-0c[`pass:v[operator<=]`] |

|xref:boost-urls-grammar-string_view_base-8friend-095[`pass:v[operator==]`] |

|xref:boost-urls-grammar-string_view_base-8friend-0d[`pass:v[operator>]`] |

|xref:boost-urls-grammar-string_view_base-8friend-02[`pass:v[operator>=]`] |

|===

== Description

pass:v,q[This base class is used to provide common] pass:v,q[member functions for reference types that]
pass:v,q[behave like string views. This cannot be]
pass:v,q[instantiated directly; Instead, derive]
pass:v,q[from the type and provide constructors]
pass:v,q[which offer any desired preconditions]
pass:v,q[and invariants.]




[#boost-urls-grammar-string_view_base-traits_type]

= string_view_base::traits_type

pass:v,q[The character traits]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L87[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef char_traits<char> traits_type;
----


[#boost-urls-grammar-string_view_base-value_type]

= string_view_base::value_type

pass:v,q[The value type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L89[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef char value_type;
----


[#boost-urls-grammar-string_view_base-pointer]

= string_view_base::pointer

pass:v,q[The pointer type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L91[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef char* pointer;
----


[#boost-urls-grammar-string_view_base-const_pointer]

= string_view_base::const_pointer

pass:v,q[The const pointer type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L93[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef const char* const_pointer;
----


[#boost-urls-grammar-string_view_base-reference]

= string_view_base::reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L95[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef char& reference;
----


[#boost-urls-grammar-string_view_base-const_reference]

= string_view_base::const_reference

pass:v,q[The const reference type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L97[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef const char& const_reference;
----


[#boost-urls-grammar-string_view_base-const_iterator]

= string_view_base::const_iterator

pass:v,q[The const iterator type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L99[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef const char* const_iterator;
----


[#boost-urls-grammar-string_view_base-iterator]

= string_view_base::iterator

pass:v,q[The iterator type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L101[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef xref:boost-urls-grammar-string_view_base-const_iterator[const_iterator] iterator;
----


[#boost-urls-grammar-string_view_base-const_reverse_iterator]

= string_view_base::const_reverse_iterator

pass:v,q[The const reverse iterator type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L103[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef reverse_iterator<xref:boost-urls-grammar-string_view_base-const_iterator[const_iterator]> const_reverse_iterator;
----


[#boost-urls-grammar-string_view_base-reverse_iterator]

= string_view_base::reverse_iterator

pass:v,q[The reverse iterator type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L106[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef xref:boost-urls-grammar-string_view_base-const_reverse_iterator[const_reverse_iterator] reverse_iterator;
----


[#boost-urls-grammar-string_view_base-size_type]

= string_view_base::size_type

pass:v,q[The size type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L108[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef size_t size_type;
----


[#boost-urls-grammar-string_view_base-difference_type]

= string_view_base::difference_type

pass:v,q[The difference type]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L110[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef ptrdiff_t difference_type;
----


[#boost-urls-grammar-string_view_base-npos]

= string_view_base::npos

pass:v,q[A constant used to represent "no position"]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L113[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
const size_t npos;
----


[#boost-urls-grammar-string_view_base-2conversion-0e]

= Function string_view_base::operator string_view

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L119[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator string_view() const noexcept;
----


[#boost-urls-grammar-string_view_base-2conversion-06]

= Function string_view_base::operator string

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L142[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator string() const noexcept;
----

== Description

pass:v,q[Conversion to std::string is explicit] pass:v,q[because assigning to string using an]
pass:v,q[implicit constructor does not preserve]
pass:v,q[capacity.]



== Return Value

* `string` 





[#boost-urls-grammar-string_view_base-begin]

= Function string_view_base::begin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L157[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_iterator[const_iterator]
begin() const noexcept;
----

== Description

pass:v,q[See `core::string_view::begin`]



== Return Value

* `const_iterator` 





[#boost-urls-grammar-string_view_base-end]

= Function string_view_base::end

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L166[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_iterator[const_iterator]
end() const noexcept;
----

== Description

pass:v,q[See `core::string_view::end`]



== Return Value

* `const_iterator` 





[#boost-urls-grammar-string_view_base-cbegin]

= Function string_view_base::cbegin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L175[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_iterator[const_iterator]
cbegin() const noexcept;
----

== Description

pass:v,q[See `core::string_view::cbegin`]



== Return Value

* `const_iterator` 





[#boost-urls-grammar-string_view_base-cend]

= Function string_view_base::cend

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L184[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_iterator[const_iterator]
cend() const noexcept;
----

== Description

pass:v,q[See `core::string_view::cend`]



== Return Value

* `const_iterator` 





[#boost-urls-grammar-string_view_base-rbegin]

= Function string_view_base::rbegin



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L194[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reverse_iterator[const_reverse_iterator]
rbegin() const noexcept;
----


[#boost-urls-grammar-string_view_base-rend]

= Function string_view_base::rend



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L206[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reverse_iterator[const_reverse_iterator]
rend() const noexcept;
----


[#boost-urls-grammar-string_view_base-crbegin]

= Function string_view_base::crbegin



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L218[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reverse_iterator[const_reverse_iterator]
crbegin() const noexcept;
----


[#boost-urls-grammar-string_view_base-crend]

= Function string_view_base::crend



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L230[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reverse_iterator[const_reverse_iterator]
crend() const noexcept;
----


[#boost-urls-grammar-string_view_base-size]

= Function string_view_base::size

pass:v,q[Return the size]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L243[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
size() const noexcept;
----

== Description

pass:v,q[See `core::string_view::size`]



== Return Value

* `size_type` 





[#boost-urls-grammar-string_view_base-length]

= Function string_view_base::length

pass:v,q[Return the size]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L252[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
length() const noexcept;
----

== Description

pass:v,q[See `core::string_view::length`]



== Return Value

* `size_type` 





[#boost-urls-grammar-string_view_base-max_size]

= Function string_view_base::max_size

pass:v,q[Return the maximum allowed size]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L261[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
max_size() const noexcept;
----

== Description

pass:v,q[See `core::string_view::max_size`]



== Return Value

* `size_type` 





[#boost-urls-grammar-string_view_base-empty]

= Function string_view_base::empty

pass:v,q[Return true if the string is empty]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L270[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
empty() const noexcept;
----

== Description

pass:v,q[See `core::string_view::size`]



== Return Value

* `bool` 





[#boost-urls-grammar-string_view_base-operator_subs]

= Function string_view_base::operator[]

pass:v,q[Access a character]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L281[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reference[const_reference]
operator[](xref:boost-urls-grammar-string_view_base-size_type[size_type] pos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::operator[]`]



== Return Value

* `const_reference` 


== Parameters

|===
| Name | Type 

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-at]

= Function string_view_base::at

pass:v,q[Access a character]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L291[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reference[const_reference]
at(xref:boost-urls-grammar-string_view_base-size_type[size_type] pos) const;
----

== Description

pass:v,q[See `core::string_view::at`]



== Return Value

* `const_reference` 


== Parameters

|===
| Name | Type 

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-front]

= Function string_view_base::front

pass:v,q[Return the first character]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L301[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reference[const_reference]
front() const noexcept;
----

== Description

pass:v,q[See `core::string_view::front`]



== Return Value

* `const_reference` 





[#boost-urls-grammar-string_view_base-back]

= Function string_view_base::back

pass:v,q[Return the last character]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L311[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_reference[const_reference]
back() const noexcept;
----

== Description

pass:v,q[See `core::string_view::back`]



== Return Value

* `const_reference` 





[#boost-urls-grammar-string_view_base-data]

= Function string_view_base::data

pass:v,q[Return a pointer to the character buffer]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L321[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-const_pointer[const_pointer]
data() const noexcept;
----

== Description

pass:v,q[See `core::string_view::data`]



== Return Value

* `const_pointer` 





[#boost-urls-grammar-string_view_base-copy]

= Function string_view_base::copy

pass:v,q[Copy the characters to another buffer]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L333[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
copy(
    char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const;
----

== Description

pass:v,q[See `core::string_view::copy`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *n*
| `size_type`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-substr]

= Function string_view_base::substr

pass:v,q[Return a view to part of the string]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L343[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
string_view
substr(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n = core::string_view::npos) const;
----

== Description

pass:v,q[See `core::string_view::substr`]



== Return Value

* `string_view` 


== Parameters

|===
| Name | Type 

| *pos*
| `size_type`

| *n*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-compare]

= Overload set string_view_base::compare

== Members


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(string_view str) const noexcept;
  xref:boost-urls-grammar-string_view_base-compare-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    string_view str) const;
  xref:boost-urls-grammar-string_view_base-compare-0a[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos2,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n2) const;
  xref:boost-urls-grammar-string_view_base-compare-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(const char* s) const noexcept;
  xref:boost-urls-grammar-string_view_base-compare-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    const char* s) const;
  xref:boost-urls-grammar-string_view_base-compare-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n2) const;
  xref:boost-urls-grammar-string_view_base-compare-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-starts_with]

= Overload set string_view_base::starts_with

== Members


pass:v,q[Return true if a matching prefix exists]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
starts_with(string_view x) const noexcept;
  xref:boost-urls-grammar-string_view_base-starts_with-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if a matching prefix exists]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
starts_with(char x) const noexcept;
  xref:boost-urls-grammar-string_view_base-starts_with-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if a matching prefix exists]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
starts_with(const char* x) const noexcept;
  xref:boost-urls-grammar-string_view_base-starts_with-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-ends_with]

= Overload set string_view_base::ends_with

== Members


pass:v,q[Return true if a matching suffix exists]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
ends_with(string_view x) const noexcept;
  xref:boost-urls-grammar-string_view_base-ends_with-0a[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if a matching suffix exists]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
ends_with(char x) const noexcept;
  xref:boost-urls-grammar-string_view_base-ends_with-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if a matching suffix exists]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
ends_with(const char* x) const noexcept;
  xref:boost-urls-grammar-string_view_base-ends_with-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-find]

= Overload set string_view_base::find

== Members


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find-00[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
  xref:boost-urls-grammar-string_view_base-find-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-rfind]

= Overload set string_view_base::rfind

== Members


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-rfind-0ed[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-rfind-0eb[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
  xref:boost-urls-grammar-string_view_base-rfind-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of matching characters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-rfind-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-find_first_of]

= Overload set string_view_base::find_first_of

== Members


pass:v,q[Return the position of the first match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_of-0ab[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the first match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_of-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the first match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_of-0af[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the first match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_of-08[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-find_last_of]

= Overload set string_view_base::find_last_of

== Members


pass:v,q[Return the position of the last match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_of-00[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the last match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_of-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the last match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_of-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the last match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_of-08[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-find_first_not_of]

= Overload set string_view_base::find_first_not_of

== Members


pass:v,q[Return the position of the first non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_not_of-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the first non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_not_of-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the first non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_not_of-0a[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the first non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_first_not_of-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-find_last_not_of]

= Overload set string_view_base::find_last_not_of

== Members


pass:v,q[Return the position of the last non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_not_of-03[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the last non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_not_of-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the last non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_not_of-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the position of the last non-match]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
  xref:boost-urls-grammar-string_view_base-find_last_not_of-06[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-contains]

= Overload set string_view_base::contains

== Members


pass:v,q[Return true if matching characters are found]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
contains(string_view sv) const noexcept;
  xref:boost-urls-grammar-string_view_base-contains-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if matching characters are found]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
contains(char c) const noexcept;
  xref:boost-urls-grammar-string_view_base-contains-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if matching characters are found]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
contains(const char* s) const noexcept;
  xref:boost-urls-grammar-string_view_base-contains-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-string_view_base-8friend-095]

= Friend operator==



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L775[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator==(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-string_view_base-8friend-017]

= Friend operator!=



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L784[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator!=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-string_view_base-8friend-010]

= Friend operator<



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L793[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-string_view_base-8friend-0c]

= Friend operator<=



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L802[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-string_view_base-8friend-0d]

= Friend operator>



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L811[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-string_view_base-8friend-02]

= Friend operator>=



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L820[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-string_view_base-8friend-09d]

= Friend hash_value

pass:v,q[Return the hash of this value]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L834[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
size_t
hash_value(const xref:boost-urls-grammar-string_view_base[string_view_base]& s) noexcept;
----


[#boost-urls-grammar-string_view_base-8friend-00]

= Friend operator<<



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L843[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-grammar-string_view_base[string_view_base]& s);
----


[#boost-urls-grammar-operator_eq]

= Function operator==



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L776[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator==(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-operator_not_eq]

= Function operator!=



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L785[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator!=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-operator_lt]

= Function operator<



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L794[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-operator_le]

= Function operator<=



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L803[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-operator_gt]

= Function operator>



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L812[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-operator_ge]

= Function operator>=



== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L821[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-grammar-hash_value]

= Function hash_value

pass:v,q[Return the hash of this value]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L834[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
hash_value(const xref:boost-urls-grammar-string_view_base[string_view_base]& s) noexcept;
----


[#boost-urls-grammar-operator_lshift]

= Function operator<<

pass:v,q[Format a string to an output stream]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L855[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-grammar-string_view_base[string_view_base]& s);
----


[#boost-urls-grammar-all_chars_t]

= Class all_chars_t



== Synopsis

Declared in header `</boost/url/grammar/all_chars.hpp#L43[boost/url/grammar/all_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct all_chars_t;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-all_chars_t-2constructor[`pass:v[all_chars_t]`] |

|xref:boost-urls-grammar-all_chars_t-find_if[`pass:v[find_if]`] |

|xref:boost-urls-grammar-all_chars_t-find_if_not[`pass:v[find_if_not]`] |

|xref:boost-urls-grammar-all_chars_t-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-all_chars_t-2constructor]

= Function all_chars_t::all_chars_t



== Synopsis

Declared in header `</boost/url/grammar/all_chars.hpp#L45[boost/url/grammar/all_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
all_chars_t() noexcept = default;
----


[#boost-urls-grammar-all_chars_t-operator_call]

= Function all_chars_t::operator()



== Synopsis

Declared in header `</boost/url/grammar/all_chars.hpp#L48[boost/url/grammar/all_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
operator()(char) const noexcept;
----


[#boost-urls-grammar-all_chars_t-find_if]

= Function all_chars_t::find_if



== Synopsis

Declared in header `</boost/url/grammar/all_chars.hpp#L56[boost/url/grammar/all_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-all_chars_t-find_if_not]

= Function all_chars_t::find_if_not



== Synopsis

Declared in header `</boost/url/grammar/all_chars.hpp#L65[boost/url/grammar/all_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if_not(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-all_chars]

= all_chars

pass:v,q[A character set containing all characters.]


== Synopsis

Declared in header `</boost/url/grammar/all_chars.hpp#L81[boost/url/grammar/all_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar-all_chars_t[all_chars_t] all_chars;
----


[#boost-urls-grammar-hexdig_chars_t]

= Class hexdig_chars_t



== Synopsis

Declared in header `</boost/url/grammar/hexdig_chars.hpp#L61[boost/url/grammar/hexdig_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct hexdig_chars_t;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-hexdig_chars_t-find_if[`pass:v[find_if]`] |

|xref:boost-urls-grammar-hexdig_chars_t-find_if_not[`pass:v[find_if_not]`] |

|xref:boost-urls-grammar-hexdig_chars_t-operator_call[`pass:v[operator()]`] |
pass:v,q[Return true if c is in the character set.]

|===



[#boost-urls-grammar-hexdig_chars_t-operator_call]

= Function hexdig_chars_t::operator()

pass:v,q[Return true if c is in the character set.]


== Synopsis

Declared in header `</boost/url/grammar/hexdig_chars.hpp#L65[boost/url/grammar/hexdig_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
operator()(char c) const noexcept;
----


[#boost-urls-grammar-hexdig_chars_t-find_if]

= Function hexdig_chars_t::find_if



== Synopsis

Declared in header `</boost/url/grammar/hexdig_chars.hpp#L76[boost/url/grammar/hexdig_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-hexdig_chars_t-find_if_not]

= Function hexdig_chars_t::find_if_not



== Synopsis

Declared in header `</boost/url/grammar/hexdig_chars.hpp#L85[boost/url/grammar/hexdig_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if_not(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-hexdig_chars]

= hexdig_chars



== Synopsis

Declared in header `</boost/url/grammar/hexdig_chars.hpp#L96[boost/url/grammar/hexdig_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar-hexdig_chars_t[hexdig_chars_t] hexdig_chars;
----


[#boost-urls-grammar-hexdig_value]

= Function hexdig_value

pass:v,q[Return the decimal value of a hex character]


== Synopsis

Declared in header `</boost/url/grammar/hexdig_chars.hpp#L123[boost/url/grammar/hexdig_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
signed char
hexdig_value(char ch) noexcept;
----

== Description

pass:v,q[This function returns the decimal] pass:v,q[value of a hexadecimal character,]
pass:v,q[or -1 if the argument is not a]
pass:v,q[valid hexadecimal digit.]

=== BNF
[,cpp]
----
HEXDIG      = DIGIT
            / "A" / "B" / "C" / "D" / "E" / "F"
            / "a" / "b" / "c" / "d" / "e" / "f"
----



== Return Value

* `signed char` 


== Parameters

|===
| Name | Type 

| *ch*
| `char`

|===




[#boost-urls-grammar-is_charset-06]

= Class is_charset



== Synopsis

Declared in header `</boost/url/grammar/charset.hpp#L51[boost/url/grammar/charset.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class T,
    class = void>
struct is_charset
    : xref:std[std]::xref:std-false_type[false_type];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-type[`pass:v[type]`] |

|xref:std-integral_constant-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-2conversion[`pass:v[operator std::integral_constant::value_type]`] |

|xref:std-integral_constant-operator_call[`pass:v[operator()]`] |

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-value[`pass:v[value]`] |

|===



[#boost-urls-grammar-is_charset-0c]

= Class is_charset



== Synopsis

Declared in header `</boost/url/grammar/charset.hpp#L54[boost/url/grammar/charset.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
struct xref:boost-urls-grammar-is_charset-06[is_charset]<T, xref:boost-urls-void_t[void_t]<decltype(std::declval<bool&>() =
                std::declval<T const&>().operator()(
                    std::declval<char>()))>>
    : xref:std[std]::xref:std-true_type[true_type];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-type[`pass:v[type]`] |

|xref:std-integral_constant-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-2conversion[`pass:v[operator std::integral_constant::value_type]`] |

|xref:std-integral_constant-operator_call[`pass:v[operator()]`] |

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-value[`pass:v[value]`] |

|===



[#boost-urls-grammar-find_if]

= Function find_if

pass:v,q[Find the first character in the string that is in the set.]


== Synopsis

Declared in header `</boost/url/grammar/charset.hpp#L86[boost/url/grammar/charset.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
const char*
find_if(
    const char* const first,
    const char* const last,
    const CharSet& cs) noexcept;
----

== Description


=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *first*
| ``

| *last*
| ``

| *cs*
| ``

|===




[#boost-urls-grammar-find_if_not]

= Function find_if_not

pass:v,q[Find the first character in the string that is not in CharSet]


== Synopsis

Declared in header `</boost/url/grammar/charset.hpp#L124[boost/url/grammar/charset.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
const char*
find_if_not(
    const char* const first,
    const char* const last,
    const CharSet& cs) noexcept;
----

== Description


=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *first*
| ``

| *last*
| ``

| *cs*
| ``

|===




[#boost-urls-grammar-ref]

= Overload set ref

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
constexpr
enable_if<is_charset<CharSet>::value && !std::is_same<CharSet, detail::charset_ref<CharSet>>::value, charset_ref<CharSet>>::type
ref(const CharSet& cs) noexcept;
  xref:boost-urls-grammar-ref-07[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
constexpr
enable_if<is_rule<Rule>::value && !std::is_same<Rule, detail::rule_ref<Rule>>::value, rule_ref<Rule>>::type
ref(const Rule& r) noexcept;
  xref:boost-urls-grammar-ref-03[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
void
ref() = delete;
  xref:boost-urls-grammar-ref-01[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-is_rule-0a]

= Class is_rule



== Synopsis

Declared in header `</boost/url/grammar/type_traits.hpp#L51[boost/url/grammar/type_traits.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class T,
    class = void>
struct is_rule
    : xref:std[std]::xref:std-false_type[false_type];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-type[`pass:v[type]`] |

|xref:std-integral_constant-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-2conversion[`pass:v[operator std::integral_constant::value_type]`] |

|xref:std-integral_constant-operator_call[`pass:v[operator()]`] |

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-value[`pass:v[value]`] |

|===



[#boost-urls-grammar-is_rule-0f]

= Class is_rule



== Synopsis

Declared in header `</boost/url/grammar/type_traits.hpp#L54[boost/url/grammar/type_traits.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
struct xref:boost-urls-grammar-is_rule-0a[is_rule]<T, xref:boost-urls-void_t[void_t]<decltype(std::declval<system::result<typename T::value_type>&>() =
                std::declval<T const&>().parse(
                    std::declval<char const*&>(),
                    std::declval<char const*>()))>>
    : xref:std[std]::xref:std-is_nothrow_copy_constructible[is_nothrow_copy_constructible]<T>;
----




[#boost-urls-grammar-parse]

= Overload set parse

== Members


pass:v,q[Parse a character buffer using a rule]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R>
result<Rule::value_type>
parse(
    const char*& it,
    const char* end,
    const Rule& r);
  xref:boost-urls-grammar-parse-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Parse a character buffer using a rule]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R>
result<Rule::value_type>
parse(
    string_view s,
    const Rule& r);
  xref:boost-urls-grammar-parse-02[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-error]

= Enum error

pass:v,q[Error codes returned when using rules]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L26[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
enum error : int;
----

== Members
[,cols=2]
|===
|Name |Description
|need_more |pass:v,q[More input is needed to match the rule]

|mismatch |pass:v,q[The rule did not match the input.]

|end_of_range |pass:v,q[A rule reached the end of a range]

|leftover |pass:v,q[Leftover input remaining after match.]

|invalid |pass:v,q[A rule encountered unrecoverable invalid input.]

|out_of_range |pass:v,q[An integer overflowed during parsing.]

|syntax |pass:v,q[An unspecified syntax error was found.]

|===


[#boost-urls-grammar-error-need_more]

= Enumerator error::need_more

pass:v,q[More input is needed to match the rule]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L48[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
need_more = 1
----

== Description

pass:v,q[A rule reached the end of the input,] pass:v,q[resulting in a partial match. The error]
pass:v,q[is recoverable; the caller may obtain]
pass:v,q[more input if possible and attempt to]
pass:v,q[parse the character buffer again.]
pass:v,q[Custom rules should only return this]
pass:v,q[error if it is completely unambiguous]
pass:v,q[that the rule cannot be matched without]
pass:v,q[more input.]



[#boost-urls-grammar-error-mismatch]

= Enumerator error::mismatch

pass:v,q[The rule did not match the input.]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L58[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
mismatch
----

== Description

pass:v,q[This error is returned when a rule fails] pass:v,q[to match the input. The error is recoverable;]
pass:v,q[the caller may rewind the input pointer and]
pass:v,q[attempt to parse again using a different rule.]



[#boost-urls-grammar-error-end_of_range]

= Enumerator error::end_of_range

pass:v,q[A rule reached the end of a range]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L71[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
end_of_range
----

== Description

pass:v,q[This indicates that the input was consumed] pass:v,q[when parsing a] xref:boost-urls-grammar-range[range.]
pass:v,q[The]
xref:boost-urls-grammar-range_rule-02[range_rule]
pass:v,q[avoids rewinding the input buffer when]
pass:v,q[this error is returned. Thus the consumed]
pass:v,q[characters are be considered part of the]
pass:v,q[range without contributing additional]
pass:v,q[elements.]



[#boost-urls-grammar-error-leftover]

= Enumerator error::leftover

pass:v,q[Leftover input remaining after match.]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L76[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
leftover
----


[#boost-urls-grammar-error-invalid]

= Enumerator error::invalid

pass:v,q[A rule encountered unrecoverable invalid input.]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L94[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
invalid
----

== Description

pass:v,q[This error is returned when input is matching] pass:v,q[but one of the requirements is violated. For]
pass:v,q[example if a percent escape is found, but]
pass:v,q[one or both characters that follow are not]
pass:v,q[valid hexadecimal digits. This is usually an]
pass:v,q[unrecoverable error.]



[#boost-urls-grammar-error-out_of_range]

= Enumerator error::out_of_range

pass:v,q[An integer overflowed during parsing.]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L98[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
out_of_range
----


[#boost-urls-grammar-error-syntax]

= Enumerator error::syntax

pass:v,q[An unspecified syntax error was found.]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L103[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
syntax
----


[#boost-urls-grammar-condition]

= Enum condition

pass:v,q[Error conditions for errors received from rules]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L114[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
enum condition : int;
----

== Members
[,cols=2]
|===
|Name |Description
|fatal |pass:v,q[A fatal error in syntax was encountered.]

|===


[#boost-urls-grammar-condition-fatal]

= Enumerator condition::fatal

pass:v,q[A fatal error in syntax was encountered.]


== Synopsis

Declared in header `</boost/url/grammar/error.hpp#L121[boost/url/grammar/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
fatal = 1
----

== Description

pass:v,q[This indicates that parsing cannot continue.]



[#boost-urls-grammar-make_error_code]

= Function make_error_code



== Synopsis

Declared in header `</boost/url/grammar/impl/error.hpp#L97[boost/url/grammar/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
error_code
make_error_code(xref:boost-urls-grammar-error[error] ev) noexcept;
----


[#boost-urls-grammar-make_error_condition]

= Function make_error_condition



== Synopsis

Declared in header `</boost/url/grammar/impl/error.hpp#L108[boost/url/grammar/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
error_condition
make_error_condition(xref:boost-urls-grammar-condition[condition] c) noexcept;
----


[#boost-urls-grammar-to_lower]

= Function to_lower

pass:v,q[Return c converted to lowercase]


== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L53[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
char
to_lower(char c) noexcept;
----

== Description

pass:v,q[This function returns the character,] pass:v,q[converting it to lowercase if it is]
pass:v,q[uppercase.]
pass:v,q[The function is defined only for]
pass:v,q[low-ASCII characters.]

=== Example
[,cpp]
----
assert( to_lower( 'A' ) == 'a' );
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `char` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

|===




[#boost-urls-grammar-to_upper]

= Function to_upper

pass:v,q[Return c converted to uppercase]


== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L83[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
char
to_upper(char c) noexcept;
----

== Description

pass:v,q[This function returns the character,] pass:v,q[converting it to uppercase if it is]
pass:v,q[lowercase.]
pass:v,q[The function is defined only for]
pass:v,q[low-ASCII characters.]

=== Example
[,cpp]
----
assert( to_upper( 'a' ) == 'A' );
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `char` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

|===




[#boost-urls-grammar-ci_compare]

= Function ci_compare

pass:v,q[Return the case-insensitive comparison of s0 and s1]


== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L120[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
int
ci_compare(
    string_view s0,
    string_view s1) noexcept;
----

== Description

pass:v,q[This returns the lexicographical comparison] pass:v,q[of two strings, ignoring case.]
pass:v,q[The function is defined only for strings]
pass:v,q[containing low-ASCII characters.]

=== Example
[,cpp]
----
assert( ci_compare( "boost", "Boost" ) == 0 );
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *s0*
| `string_view`

| *s1*
| `string_view`

|===




[#boost-urls-grammar-ci_digest]

= Function ci_digest

pass:v,q[Return the case-insensitive digest of a string]


== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L140[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
ci_digest(string_view s) noexcept;
----

== Description

pass:v,q[The hash function is non-cryptographic and] pass:v,q[not hardened against algorithmic complexity]
pass:v,q[attacks.]
pass:v,q[Returned digests are suitable for usage in]
pass:v,q[unordered containers.]
pass:v,q[The function is defined only for strings]
pass:v,q[containing low-ASCII characters.]



== Return Value

* `size_t` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-grammar-ci_is_equal]

= Overload set ci_is_equal

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class String0,
    class String1>
enable_if<!std::is_convertible<String0, core::string_view>::value || !std::is_convertible<String1, core::string_view>::value, bool>::type
ci_is_equal(
    const String0& s0,
    const String1& s1);
  xref:boost-urls-grammar-ci_is_equal-0a[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
ci_is_equal(
    string_view s0,
    string_view s1) noexcept;
  xref:boost-urls-grammar-ci_is_equal-0b[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-ci_is_less]

= Function ci_is_less

pass:v,q[Return true if s0 is less than s1 using case-insensitive comparison]


== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L224[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
ci_is_less(
    string_view s0,
    string_view s1) noexcept;
----

== Description

pass:v,q[The comparison algorithm implements a] pass:v,q[case-insensitive total order on the set]
pass:v,q[of all strings; however, it is not a]
pass:v,q[lexicographical comparison.]
pass:v,q[The function is defined only for strings]
pass:v,q[containing low-ASCII characters.]

=== Example
[,cpp]
----
assert( ! ci_is_less( "Boost", "boost" ) );
----



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *s0*
| `string_view`

| *s1*
| `string_view`

|===




[#boost-urls-grammar-ci_hash]

= Class ci_hash



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L261[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct ci_hash;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ci_hash-is_transparent[`pass:v[is_transparent]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ci_hash-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-ci_hash-is_transparent]

= ci_hash::is_transparent



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L263[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using is_transparent = void;
----


[#boost-urls-grammar-ci_hash-operator_call]

= Function ci_hash::operator()



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L265[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
operator()(string_view s) const noexcept;
----


[#boost-urls-grammar-ci_equal]

= Class ci_equal



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L297[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct ci_equal;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ci_equal-is_transparent[`pass:v[is_transparent]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ci_equal-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-ci_equal-is_transparent]

= ci_equal::is_transparent



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L299[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using is_transparent = void;
----


[#boost-urls-grammar-ci_equal-operator_call]

= Function ci_equal::operator()



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L303[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class String0,
    class String1>
bool
operator()(
    String0 s0,
    String1 s1) const noexcept;
----


[#boost-urls-grammar-ci_less]

= Class ci_less



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L338[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct ci_less;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ci_less-is_transparent[`pass:v[is_transparent]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ci_less-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-ci_less-is_transparent]

= ci_less::is_transparent



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L340[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using is_transparent = void;
----


[#boost-urls-grammar-ci_less-operator_call]

= Function ci_less::operator()



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L342[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
operator()(
    string_view s0,
    string_view s1) const noexcept;
----


[#boost-urls-grammar-variant_rule_t]

= Class variant_rule_t



== Synopsis

Declared in header `</boost/url/grammar/variant_rule.hpp#L78[boost/url/grammar/variant_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0,
    class... Rn>
class variant_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-variant_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-variant_rule_t-parse[`pass:v[parse]`] |

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-variant_rule_t-8friend[`pass:v[variant_rule]`] |

|===



[#boost-urls-grammar-variant_rule_t-value_type]

= variant_rule_t::value_type



== Synopsis

Declared in header `</boost/url/grammar/variant_rule.hpp#L81[boost/url/grammar/variant_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-variant[variant]<R0::value_type, Rn::value_type...>;
----


[#boost-urls-grammar-variant_rule_t-parse]

= Function variant_rule_t::parse



== Synopsis

Declared in header `</boost/url/grammar/variant_rule.hpp#L85[boost/url/grammar/variant_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-variant_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const;
----


[#boost-urls-grammar-variant_rule_t-8friend]

= Friend variant_rule



== Synopsis

Declared in header `</boost/url/grammar/variant_rule.hpp#L91[boost/url/grammar/variant_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0_,
    class... Rn_>
friend
constexpr
xref:boost-urls-grammar-variant_rule_t[variant_rule_t]<R0_, Rn_...>
variant_rule(
    const R0_& r0,
    const Rn_&... rn) noexcept;
----


[#boost-urls-grammar-variant_rule]

= Overload set variant_rule

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0_,
    class... Rn_>
constexpr
xref:boost-urls-grammar-variant_rule_t[variant_rule_t]<R0_, Rn_...>
variant_rule(
    const R0_& r0,
    const Rn_&... rn) noexcept;
  xref:boost-urls-grammar-variant_rule-0b[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0,
    class... Rn>
constexpr
xref:boost-urls-grammar-variant_rule_t[variant_rule_t]<R0, Rn...>
variant_rule(
    const R0& r0,
    const Rn&... rn) noexcept;
  xref:boost-urls-grammar-variant_rule-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-unsigned_rule]

= Class unsigned_rule



== Synopsis

Declared in header `</boost/url/grammar/unsigned_rule.hpp#L57[boost/url/grammar/unsigned_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Unsigned>
struct unsigned_rule;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-unsigned_rule-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-unsigned_rule-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-unsigned_rule-value_type]

= unsigned_rule::value_type



== Synopsis

Declared in header `</boost/url/grammar/unsigned_rule.hpp#L65[boost/url/grammar/unsigned_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = Unsigned;
----


[#boost-urls-grammar-unsigned_rule-parse]

= Function unsigned_rule::parse



== Synopsis

Declared in header `</boost/url/grammar/unsigned_rule.hpp#L67[boost/url/grammar/unsigned_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-unsigned_rule-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-grammar-digit_chars_t]

= Class digit_chars_t



== Synopsis

Declared in header `</boost/url/grammar/digit_chars.hpp#L48[boost/url/grammar/digit_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct digit_chars_t;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-digit_chars_t-find_if[`pass:v[find_if]`] |

|xref:boost-urls-grammar-digit_chars_t-find_if_not[`pass:v[find_if_not]`] |

|xref:boost-urls-grammar-digit_chars_t-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-digit_chars_t-operator_call]

= Function digit_chars_t::operator()



== Synopsis

Declared in header `</boost/url/grammar/digit_chars.hpp#L50[boost/url/grammar/digit_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
operator()(char c) const noexcept;
----


[#boost-urls-grammar-digit_chars_t-find_if]

= Function digit_chars_t::find_if



== Synopsis

Declared in header `</boost/url/grammar/digit_chars.hpp#L58[boost/url/grammar/digit_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-digit_chars_t-find_if_not]

= Function digit_chars_t::find_if_not



== Synopsis

Declared in header `</boost/url/grammar/digit_chars.hpp#L67[boost/url/grammar/digit_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if_not(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-digit_chars]

= digit_chars



== Synopsis

Declared in header `</boost/url/grammar/digit_chars.hpp#L78[boost/url/grammar/digit_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar-digit_chars_t[digit_chars_t] digit_chars;
----


[#boost-urls-grammar-ch_delim_rule]

= Class ch_delim_rule



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L61[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct ch_delim_rule;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ch_delim_rule-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-ch_delim_rule-2constructor[`pass:v[ch_delim_rule]`] |

|xref:boost-urls-grammar-ch_delim_rule-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-ch_delim_rule-value_type]

= ch_delim_rule::value_type



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L63[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = string_view;
----


[#boost-urls-grammar-ch_delim_rule-2constructor]

= Function ch_delim_rule::ch_delim_rule



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L65[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ch_delim_rule(char ch) noexcept;
----


[#boost-urls-grammar-ch_delim_rule-parse]

= Function ch_delim_rule::parse



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L72[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-ch_delim_rule-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-grammar-delim_rule]

= Overload set delim_rule

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-ch_delim_rule[ch_delim_rule]
delim_rule(char ch) noexcept;
  xref:boost-urls-grammar-delim_rule-02[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
constexpr
enable_if<!std::is_convertible<CharSet, char>::value, xref:boost-urls-grammar-cs_delim_rule[cs_delim_rule]<CharSet>>::type
delim_rule(const CharSet& cs) noexcept;
  xref:boost-urls-grammar-delim_rule-0a[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-cs_delim_rule]

= Class cs_delim_rule



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L127[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
struct cs_delim_rule;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-cs_delim_rule-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-cs_delim_rule-2constructor[`pass:v[cs_delim_rule]`] |

|xref:boost-urls-grammar-cs_delim_rule-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-cs_delim_rule-value_type]

= cs_delim_rule::value_type



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L129[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = string_view;
----


[#boost-urls-grammar-cs_delim_rule-2constructor]

= Function cs_delim_rule::cs_delim_rule



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L131[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
cs_delim_rule(const CharSet& cs) noexcept;
----


[#boost-urls-grammar-cs_delim_rule-parse]

= Function cs_delim_rule::parse



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L138[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-cs_delim_rule-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-grammar-optional_rule_t]

= Class optional_rule_t



== Synopsis

Declared in header `</boost/url/grammar/optional_rule.hpp#L65[boost/url/grammar/optional_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
struct optional_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-optional_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-optional_rule_t-parse[`pass:v[parse]`] |

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-optional_rule_t-8friend[`pass:v[optional_rule]`] |

|===



[#boost-urls-grammar-optional_rule_t-value_type]

= optional_rule_t::value_type



== Synopsis

Declared in header `</boost/url/grammar/optional_rule.hpp#L68[boost/url/grammar/optional_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = optional<Rule::value_type>;
----


[#boost-urls-grammar-optional_rule_t-parse]

= Function optional_rule_t::parse



== Synopsis

Declared in header `</boost/url/grammar/optional_rule.hpp#L71[boost/url/grammar/optional_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-optional_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const;
----


[#boost-urls-grammar-optional_rule_t-8friend]

= Friend optional_rule



== Synopsis

Declared in header `</boost/url/grammar/optional_rule.hpp#L76[boost/url/grammar/optional_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R_>
friend
constexpr
xref:boost-urls-grammar-optional_rule_t[optional_rule_t]<R_>
optional_rule(const R_& r);
----


[#boost-urls-grammar-optional_rule]

= Overload set optional_rule

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R_>
constexpr
xref:boost-urls-grammar-optional_rule_t[optional_rule_t]<R_>
optional_rule(const R_& r);
  xref:boost-urls-grammar-optional_rule-0c[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
constexpr
xref:boost-urls-grammar-optional_rule_t[optional_rule_t]<Rule>
optional_rule(const Rule& r);
  xref:boost-urls-grammar-optional_rule-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-tuple_rule_t]

= Class tuple_rule_t



== Synopsis

Declared in header `</boost/url/grammar/tuple_rule.hpp#L89[boost/url/grammar/tuple_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0,
    class... Rn>
class tuple_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-tuple_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-tuple_rule_t-parse[`pass:v[parse]`] |

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-tuple_rule_t-8friend[`pass:v[tuple_rule]`] |

|===



[#boost-urls-grammar-tuple_rule_t-value_type]

= tuple_rule_t::value_type



== Synopsis

Declared in header `</boost/url/grammar/tuple_rule.hpp#L102[boost/url/grammar/tuple_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = mp_eval_if_c<IsList, T, mp_first, T>;
----


[#boost-urls-grammar-tuple_rule_t-8friend]

= Friend tuple_rule



== Synopsis

Declared in header `</boost/url/grammar/tuple_rule.hpp#L106[boost/url/grammar/tuple_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0_,
    class... Rn_>
friend
constexpr
xref:boost-urls-grammar-tuple_rule_t[tuple_rule_t]<R0_, Rn_...>
tuple_rule(
    const R0_& r0,
    const Rn_&... rn) noexcept;
----


[#boost-urls-grammar-tuple_rule_t-parse]

= Function tuple_rule_t::parse



== Synopsis

Declared in header `</boost/url/grammar/tuple_rule.hpp#L117[boost/url/grammar/tuple_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-tuple_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const;
----


[#boost-urls-grammar-tuple_rule]

= Overload set tuple_rule

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0_,
    class... Rn_>
constexpr
xref:boost-urls-grammar-tuple_rule_t[tuple_rule_t]<R0_, Rn_...>
tuple_rule(
    const R0_& r0,
    const Rn_&... rn) noexcept;
  xref:boost-urls-grammar-tuple_rule-00[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0,
    class... Rn>
constexpr
xref:boost-urls-grammar-tuple_rule_t[tuple_rule_t]<R0, Rn...>
tuple_rule(
    const R0& r0,
    const Rn&... rn) noexcept;
  xref:boost-urls-grammar-tuple_rule-0e[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-squelch]

= Function squelch



== Synopsis

Declared in header `</boost/url/grammar/tuple_rule.hpp#L231[boost/url/grammar/tuple_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
constexpr
squelch_rule_t<Rule>
squelch(const Rule& r) noexcept;
----


[#boost-urls-grammar-alnum_chars_t]

= Class alnum_chars_t



== Synopsis

Declared in header `</boost/url/grammar/alnum_chars.hpp#L53[boost/url/grammar/alnum_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct alnum_chars_t;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-alnum_chars_t-find_if[`pass:v[find_if]`] |

|xref:boost-urls-grammar-alnum_chars_t-find_if_not[`pass:v[find_if_not]`] |

|xref:boost-urls-grammar-alnum_chars_t-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-alnum_chars_t-operator_call]

= Function alnum_chars_t::operator()



== Synopsis

Declared in header `</boost/url/grammar/alnum_chars.hpp#L55[boost/url/grammar/alnum_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
operator()(char c) const noexcept;
----


[#boost-urls-grammar-alnum_chars_t-find_if]

= Function alnum_chars_t::find_if



== Synopsis

Declared in header `</boost/url/grammar/alnum_chars.hpp#L66[boost/url/grammar/alnum_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-alnum_chars_t-find_if_not]

= Function alnum_chars_t::find_if_not



== Synopsis

Declared in header `</boost/url/grammar/alnum_chars.hpp#L75[boost/url/grammar/alnum_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if_not(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-alnum_chars]

= alnum_chars



== Synopsis

Declared in header `</boost/url/grammar/alnum_chars.hpp#L86[boost/url/grammar/alnum_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar-alnum_chars_t[alnum_chars_t] alnum_chars;
----


[#boost-urls-grammar-alpha_chars_t]

= Class alpha_chars_t



== Synopsis

Declared in header `</boost/url/grammar/alpha_chars.hpp#L48[boost/url/grammar/alpha_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct alpha_chars_t;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-alpha_chars_t-2constructor[`pass:v[alpha_chars_t]`] |

|xref:boost-urls-grammar-alpha_chars_t-find_if[`pass:v[find_if]`] |

|xref:boost-urls-grammar-alpha_chars_t-find_if_not[`pass:v[find_if_not]`] |

|xref:boost-urls-grammar-alpha_chars_t-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-alpha_chars_t-2constructor]

= Function alpha_chars_t::alpha_chars_t



== Synopsis

Declared in header `</boost/url/grammar/alpha_chars.hpp#L50[boost/url/grammar/alpha_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
alpha_chars_t() noexcept = default;
----


[#boost-urls-grammar-alpha_chars_t-operator_call]

= Function alpha_chars_t::operator()



== Synopsis

Declared in header `</boost/url/grammar/alpha_chars.hpp#L53[boost/url/grammar/alpha_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
operator()(char c) const noexcept;
----


[#boost-urls-grammar-alpha_chars_t-find_if]

= Function alpha_chars_t::find_if



== Synopsis

Declared in header `</boost/url/grammar/alpha_chars.hpp#L63[boost/url/grammar/alpha_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-alpha_chars_t-find_if_not]

= Function alpha_chars_t::find_if_not



== Synopsis

Declared in header `</boost/url/grammar/alpha_chars.hpp#L72[boost/url/grammar/alpha_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if_not(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-alpha_chars]

= alpha_chars

pass:v,q[A character set containing the alphabetical characters.]


== Synopsis

Declared in header `</boost/url/grammar/alpha_chars.hpp#L88[boost/url/grammar/alpha_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar-alpha_chars_t[alpha_chars_t] alpha_chars;
----


[#boost-urls-grammar-token_rule_t]

= Class token_rule_t



== Synopsis

Declared in header `</boost/url/grammar/token_rule.hpp#L57[boost/url/grammar/token_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
struct token_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-token_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-token_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-token_rule_t-value_type]

= token_rule_t::value_type



== Synopsis

Declared in header `</boost/url/grammar/token_rule.hpp#L59[boost/url/grammar/token_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = string_view;
----


[#boost-urls-grammar-token_rule_t-parse]

= Function token_rule_t::parse



== Synopsis

Declared in header `</boost/url/grammar/token_rule.hpp#L65[boost/url/grammar/token_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-token_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-grammar-token_rule]

= Function token_rule



== Synopsis

Declared in header `</boost/url/grammar/token_rule.hpp#L92[boost/url/grammar/token_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
constexpr
xref:boost-urls-grammar-token_rule_t[token_rule_t]<CharSet>
token_rule(const CharSet& cs) noexcept;
----


[#boost-urls-grammar-vchars_t]

= Class vchars_t



== Synopsis

Declared in header `</boost/url/grammar/vchars.hpp#L48[boost/url/grammar/vchars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct vchars_t;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-vchars_t-find_if[`pass:v[find_if]`] |

|xref:boost-urls-grammar-vchars_t-find_if_not[`pass:v[find_if_not]`] |

|xref:boost-urls-grammar-vchars_t-operator_call[`pass:v[operator()]`] |

|===



[#boost-urls-grammar-vchars_t-operator_call]

= Function vchars_t::operator()



== Synopsis

Declared in header `</boost/url/grammar/vchars.hpp#L50[boost/url/grammar/vchars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
operator()(char c) const noexcept;
----


[#boost-urls-grammar-vchars_t-find_if]

= Function vchars_t::find_if



== Synopsis

Declared in header `</boost/url/grammar/vchars.hpp#L58[boost/url/grammar/vchars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-vchars_t-find_if_not]

= Function vchars_t::find_if_not



== Synopsis

Declared in header `</boost/url/grammar/vchars.hpp#L67[boost/url/grammar/vchars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
find_if_not(
    const char* first,
    const char* last) const noexcept;
----


[#boost-urls-grammar-vchars]

= vchars



== Synopsis

Declared in header `</boost/url/grammar/vchars.hpp#L78[boost/url/grammar/vchars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar-vchars_t[vchars_t] vchars;
----


[#boost-urls-grammar-aligned_storage]

= aligned_storage



== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L44[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
using aligned_storage = aligned_storage_impl<detail::nearest_pow2(sizeof(T), 64), (alignof(::max_align_t) > alignof(T)) ? alignof(::max_align_t) : alignof(T)>;
----


[#boost-urls-grammar-recycled]

= Class recycled

pass:v,q[A thread-safe collection of instances of T]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L73[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
class recycled;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-recycled-2constructor[`pass:v[recycled]`] |
pass:v,q[Constructor]

|xref:boost-urls-grammar-recycled-2destructor[`pass:v[~recycled]`] |
pass:v,q[Destructor]

|===

== Description

pass:v,q[Instances of this type may be used to control] pass:v,q[where recycled instances of T come from when]
pass:v,q[used with]
xref:boost-urls-grammar-recycled_ptr[recycled_ptr.]

=== Example
[,cpp]
----
static recycled< std::string > bin;

recycled_ptr< std::string > ps( bin );

// Put the string into a known state
ps->clear();
----




[#boost-urls-grammar-recycled-2destructor]

= Function recycled::~recycled

pass:v,q[Destructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L83[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
~recycled();
----

== Description

pass:v,q[All recycled instances of T are destroyed.] pass:v,q[Undefined behavior results if there are]
pass:v,q[any]
xref:boost-urls-grammar-recycled_ptr[recycled_ptr]
pass:v,q[which reference]
pass:v,q[this recycle bin.]



== Return Value

* `void` 





[#boost-urls-grammar-recycled-2constructor]

= Function recycled::recycled

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L87[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
recycled() = default;
----


[#boost-urls-grammar-recycled_ptr]

= Class recycled_ptr

pass:v,q[A pointer to shared instance of T]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L150[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
class recycled_ptr;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-recycled_ptr-acquire[`pass:v[acquire]`] |
pass:v,q[Return the referenced object]

|xref:boost-urls-grammar-recycled_ptr-bin[`pass:v[bin]`] |
pass:v,q[Return the referenced recycle bin]

|xref:boost-urls-grammar-recycled_ptr-empty[`pass:v[empty]`] |
pass:v,q[Return true if this does not reference an object]

|xref:boost-urls-grammar-recycled_ptr-get[`pass:v[get]`] |
pass:v,q[Return the referenced object]

|xref:boost-urls-grammar-recycled_ptr-2conversion[`pass:v[operator bool]`] |
pass:v,q[Return true if this references an object]

|xref:boost-urls-grammar-recycled_ptr-operator_star[`pass:v[operator*]`] |
pass:v,q[Return the referenced object]

|xref:boost-urls-grammar-recycled_ptr-operator_ptr[`pass:v[operator->]`] |
pass:v,q[Return the referenced object]

|xref:boost-urls-grammar-recycled_ptr-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-grammar-recycled_ptr-2constructor[`pass:v[recycled_ptr]`] |
pass:v,q[Constructor]

|xref:boost-urls-grammar-recycled_ptr-release[`pass:v[release]`] |
pass:v,q[Release the referenced object]

|xref:boost-urls-grammar-recycled_ptr-2destructor[`pass:v[~recycled_ptr]`] |
pass:v,q[Destructor]

|===

== Description

pass:v,q[This is a smart pointer container which can] pass:v,q[acquire shared ownership of an instance of]
pass:v,q[`T` upon or after construction. The instance]
pass:v,q[is guaranteed to be in a valid, but unknown]
pass:v,q[state. Every recycled pointer references]
pass:v,q[a valid recycle bin.]

=== Example
[,cpp]
----
static recycled< std::string > bin;

recycled_ptr< std::string > ps( bin );

// Put the string into a known state
ps->clear();
----




[#boost-urls-grammar-recycled_ptr-2destructor]

= Function recycled_ptr::~recycled_ptr

pass:v,q[Destructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L178[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
~recycled_ptr();
----

== Description

pass:v,q[If this is not empty, shared ownership] pass:v,q[of the pointee is released. If this was]
pass:v,q[the last reference, the object is]
pass:v,q[returned to the original recycle bin.]

=== Effects
[,cpp]
----
this->release();
----



== Return Value

* `void` 





[#boost-urls-grammar-recycled_ptr-2constructor]

= Overload set recycled_ptr::recycled_ptr

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(xref:boost-urls-grammar-recycled[recycled]<T>& bin);
  xref:boost-urls-grammar-recycled_ptr-2constructor-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(
    xref:boost-urls-grammar-recycled[recycled]<T>& bin,
    nullptr_t) noexcept;
  xref:boost-urls-grammar-recycled_ptr-2constructor-0ac[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr();
  xref:boost-urls-grammar-recycled_ptr-2constructor-056[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(nullptr_t) noexcept;
  xref:boost-urls-grammar-recycled_ptr-2constructor-05e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(const xref:boost-urls-grammar-recycled_ptr[recycled_ptr]& other) noexcept;
  xref:boost-urls-grammar-recycled_ptr-2constructor-0ab[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&& other) noexcept;
  xref:boost-urls-grammar-recycled_ptr-2constructor-0f[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-recycled_ptr-operator_assign]

= Overload set recycled_ptr::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&
operator=(xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&& other) noexcept;
  xref:boost-urls-grammar-recycled_ptr-operator_assign-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&
operator=(const xref:boost-urls-grammar-recycled_ptr[recycled_ptr]& other) noexcept;
  xref:boost-urls-grammar-recycled_ptr-operator_assign-09[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-recycled_ptr-empty]

= Function recycled_ptr::empty

pass:v,q[Return true if this does not reference an object]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L403[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description


=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-grammar-recycled_ptr-2conversion]

= Function recycled_ptr::operator bool

pass:v,q[Return true if this references an object]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L419[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator bool() const noexcept;
----

== Description


=== Effects
[,cpp]
----
return ! this->empty();
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-grammar-recycled_ptr-bin]

= Function recycled_ptr::bin

pass:v,q[Return the referenced recycle bin]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L430[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-recycled[recycled]<T>&
bin() const noexcept;
----

== Description


=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-grammar-recycled_ptr-get]

= Function recycled_ptr::get

pass:v,q[Return the referenced object]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L443[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
T*
get() const noexcept;
----

== Description

pass:v,q[If this is empty, `nullptr` is returned.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-grammar-recycled_ptr-operator_ptr]

= Function recycled_ptr::operator->

pass:v,q[Return the referenced object]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L455[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
T*
operator->() const noexcept;
----

== Description

pass:v,q[If this is empty, `nullptr` is returned.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-grammar-recycled_ptr-operator_star]

= Function recycled_ptr::operator*

pass:v,q[Return the referenced object]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L467[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
T&
operator*() const noexcept;
----

== Description


=== Preconditions
[,cpp]
----
not this->empty()
----



== Return Value

* `` 





[#boost-urls-grammar-recycled_ptr-acquire]

= Function recycled_ptr::acquire

pass:v,q[Return the referenced object]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L484[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
T&
acquire();
----

== Description

pass:v,q[If this references an object, it is] pass:v,q[returned. Otherwise, exclusive ownership]
pass:v,q[of a new object of type `T` is acquired]
pass:v,q[and returned.]

=== Postconditions
[,cpp]
----
not this->empty()
----



== Return Value

* `` 





[#boost-urls-grammar-recycled_ptr-release]

= Function recycled_ptr::release

pass:v,q[Release the referenced object]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L501[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
release() noexcept;
----

== Description

pass:v,q[If this references an object, it is] pass:v,q[released to the referenced recycle bin.]
pass:v,q[The pointer continues to reference]
pass:v,q[the same recycle bin.]

=== Postconditions
[,cpp]
----
this->empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-grammar-range]

= Class range

pass:v,q[A forward range of parsed elements]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L60[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
class range;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range-const_iterator[`pass:v[const_iterator]`] |
pass:v,q[A constant, forward iterator to elements of the range]

|xref:boost-urls-grammar-range-const_reference[`pass:v[const_reference]`] |
pass:v,q[The type of each element of the range]

|xref:boost-urls-grammar-range-difference_type[`pass:v[difference_type]`] |
pass:v,q[The type used to represent signed integers]

|xref:boost-urls-grammar-range-iterator[`pass:v[iterator]`] |
pass:v,q[A constant, forward iterator to elements of the range]

|xref:boost-urls-grammar-range-pointer[`pass:v[pointer]`] |
pass:v,q[Provided for compatibility, unused]

|xref:boost-urls-grammar-range-reference[`pass:v[reference]`] |
pass:v,q[The type of each element of the range]

|xref:boost-urls-grammar-range-size_type[`pass:v[size_type]`] |
pass:v,q[The type used to represent unsigned integers]

|xref:boost-urls-grammar-range-value_type[`pass:v[value_type]`] |
pass:v,q[The type of each element of the range]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-grammar-range-empty[`pass:v[empty]`] |
pass:v,q[Return true if the range is empty]

|xref:boost-urls-grammar-range-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-grammar-range-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

pass:v,q[Constructor]

|xref:boost-urls-grammar-range-2constructor[`pass:v[range]`] |
pass:v,q[Constructor]

|xref:boost-urls-grammar-range-size[`pass:v[size]`] |
pass:v,q[Return the number of elements in the range]

|xref:boost-urls-grammar-range-string[`pass:v[string]`] |
pass:v,q[Return the matching part of the string]

|xref:boost-urls-grammar-range-2destructor[`pass:v[~range]`] |
pass:v,q[Destructor]

|===

== Description

pass:v,q[Objects of this type are forward ranges] pass:v,q[returned when parsing using the]
xref:boost-urls-grammar-range_rule-02[range_rule.]
pass:v,q[Iteration is performed by re-parsing the]
pass:v,q[underlying character buffer. Ownership]
pass:v,q[of the buffer is not transferred; the]
pass:v,q[caller is responsible for ensuring that]
pass:v,q[the lifetime of the buffer extends until]
pass:v,q[it is no longer referenced by the range.]
[NOTE]

pass:v,q[The implementation may use temporary,]
pass:v,q[recycled storage for type-erasure. Objects]
pass:v,q[of type `range` are intended to be used]
pass:v,q[ephemerally. That is, for short durations]
pass:v,q[such as within a function scope. If it is]
pass:v,q[necessary to store the range for a long]
pass:v,q[period of time or with static storage]
pass:v,q[duration, it is necessary to copy the]
pass:v,q[contents to an object of a different type.]




[#boost-urls-grammar-range-value_type]

= range::value_type

pass:v,q[The type of each element of the range]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L133[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = T;
----


[#boost-urls-grammar-range-reference]

= range::reference

pass:v,q[The type of each element of the range]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L137[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = const T&;
----


[#boost-urls-grammar-range-const_reference]

= range::const_reference

pass:v,q[The type of each element of the range]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L141[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_reference = const T&;
----


[#boost-urls-grammar-range-pointer]

= range::pointer

pass:v,q[Provided for compatibility, unused]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L145[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using pointer = const void*;
----


[#boost-urls-grammar-range-size_type]

= range::size_type

pass:v,q[The type used to represent unsigned integers]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L149[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using size_type = size_t;
----


[#boost-urls-grammar-range-difference_type]

= range::difference_type

pass:v,q[The type used to represent signed integers]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L153[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-grammar-range-iterator]

= Class range::iterator

pass:v,q[A constant, forward iterator to elements of the range]


== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L361[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class iterator;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range-iterator-difference_type[`pass:v[difference_type]`] |

|xref:boost-urls-grammar-range-iterator-iterator_category[`pass:v[iterator_category]`] |

|xref:boost-urls-grammar-range-iterator-pointer[`pass:v[pointer]`] |

|xref:boost-urls-grammar-range-iterator-reference[`pass:v[reference]`] |

|xref:boost-urls-grammar-range-iterator-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range-iterator-2constructor[`pass:v[iterator]`] |
|xref:boost-urls-grammar-range-iterator-operator_not_eq[`pass:v[operator!=]`] |

|xref:boost-urls-grammar-range-iterator-operator_star[`pass:v[operator*]`] |

|xref:boost-urls-grammar-range-iterator-operator_inc[`pass:v[operator++]`] |
|xref:boost-urls-grammar-range-iterator-operator_assign[`pass:v[operator=]`] |

|xref:boost-urls-grammar-range-iterator-operator_eq[`pass:v[operator==]`] |

|===



[#boost-urls-grammar-range-iterator-value_type]

= range::iterator::value_type



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L365[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = T;
----


[#boost-urls-grammar-range-iterator-reference]

= range::iterator::reference



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L366[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = const T&;
----


[#boost-urls-grammar-range-iterator-pointer]

= range::iterator::pointer



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L367[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using pointer = const void*;
----


[#boost-urls-grammar-range-iterator-difference_type]

= range::iterator::difference_type



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L368[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-grammar-range-iterator-iterator_category]

= range::iterator::iterator_category



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L370[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using iterator_category = forward_iterator_tag;
----


[#boost-urls-grammar-range-iterator-2constructor]

= Overload set range::iterator::iterator

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator() = default;
  xref:boost-urls-grammar-range-iterator-2constructor-05[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator(const xref:boost-urls-grammar-range-iterator[iterator]&) = default;
  xref:boost-urls-grammar-range-iterator-2constructor-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-range-iterator-operator_assign]

= Function range::iterator::operator=



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L376[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator[iterator]&
operator=(const xref:boost-urls-grammar-range-iterator[iterator]&) = default;
----


[#boost-urls-grammar-range-iterator-operator_star]

= Function range::iterator::operator*



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L379[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator-reference[reference]
operator*() const noexcept;
----


[#boost-urls-grammar-range-iterator-operator_eq]

= Function range::iterator::operator==



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L385[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(const xref:boost-urls-grammar-range-iterator[iterator]& other) const noexcept;
----


[#boost-urls-grammar-range-iterator-operator_not_eq]

= Function range::iterator::operator!=



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L396[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(const xref:boost-urls-grammar-range-iterator[iterator]& other) const noexcept;
----


[#boost-urls-grammar-range-iterator-operator_inc]

= Overload set range::iterator::operator++

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator[iterator]&
operator++() noexcept;
  xref:boost-urls-grammar-range-iterator-operator_inc-06[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator[iterator]
operator++(int) noexcept;
  xref:boost-urls-grammar-range-iterator-operator_inc-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-range-const_iterator]

= range::const_iterator

pass:v,q[A constant, forward iterator to elements of the range]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L161[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_iterator = xref:boost-urls-grammar-range-iterator[iterator];
----


[#boost-urls-grammar-range-2destructor]

= Function range::~range

pass:v,q[Destructor]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L165[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
~range();
----


[#boost-urls-grammar-range-2constructor]

= Overload set range::range

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
range() noexcept;
  xref:boost-urls-grammar-range-2constructor-01e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
range(xref:boost-urls-grammar-range[range]&& other) noexcept;
  xref:boost-urls-grammar-range-2constructor-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
range(const xref:boost-urls-grammar-range[range]& other) noexcept;
  xref:boost-urls-grammar-range-2constructor-01b[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-range-operator_assign]

= Overload set range::operator=

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range[range]&
operator=(xref:boost-urls-grammar-range[range]&& other) noexcept;
  xref:boost-urls-grammar-range-operator_assign-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range[range]&
operator=(const xref:boost-urls-grammar-range[range]& other) noexcept;
  xref:boost-urls-grammar-range-operator_assign-0e[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-range-begin]

= Function range::begin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L242[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator[iterator]
begin() const noexcept;
----


[#boost-urls-grammar-range-end]

= Function range::end

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L246[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator[iterator]
end() const noexcept;
----


[#boost-urls-grammar-range-empty]

= Function range::empty

pass:v,q[Return true if the range is empty]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L250[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----


[#boost-urls-grammar-range-size]

= Function range::size

pass:v,q[Return the number of elements in the range]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L258[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
size() const noexcept;
----


[#boost-urls-grammar-range-string]

= Function range::string

pass:v,q[Return the matching part of the string]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L266[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
string() const noexcept;
----


[#boost-urls-grammar-range_rule_t-09]

= Class range_rule_t



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L504[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0,
    class R1 = void>
struct range_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range_rule_t-09-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range_rule_t-09-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-range_rule_t-09-value_type]

= range_rule_t::value_type



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L506[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-grammar-range[range]<R0::value_type>;
----


[#boost-urls-grammar-range_rule_t-09-parse]

= Function range_rule_t::parse



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L509[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-range_rule_t-09-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const;
----


[#boost-urls-grammar-range_rule_t-01]

= Class range_rule_t



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L359[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R>
struct xref:boost-urls-grammar-range_rule_t-09[range_rule_t]<R>;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range_rule_t-01-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-range_rule_t-01-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-range_rule_t-01-value_type]

= range_rule_t::value_type



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L361[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-grammar-range[range]<R::value_type>;
----


[#boost-urls-grammar-range_rule_t-01-parse]

= Function range_rule_t::parse



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L364[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-range_rule_t-01-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const;
----


[#boost-urls-grammar-range_rule]

= Overload set range_rule

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
constexpr
xref:boost-urls-grammar-range_rule_t-09[range_rule_t]<Rule>
range_rule(
    const Rule& next,
    size_t N = 0,
    size_t M = std::size_t(-1)) noexcept;
  xref:boost-urls-grammar-range_rule-09[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class Rule1,
    class Rule2>
constexpr
enable_if<!std::is_integral<Rule2>::value, xref:boost-urls-grammar-range_rule_t-09[range_rule_t]<Rule1, Rule2>>::type
range_rule(
    const Rule1& first,
    const Rule2& next,
    size_t N = 0,
    size_t M = std::size_t(-1)) noexcept;
  xref:boost-urls-grammar-range_rule-02[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-grammar-dec_octet_rule_t]

= Class dec_octet_rule_t



== Synopsis

Declared in header `</boost/url/grammar/dec_octet_rule.hpp#L56[boost/url/grammar/dec_octet_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct dec_octet_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-dec_octet_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-dec_octet_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-dec_octet_rule_t-value_type]

= dec_octet_rule_t::value_type



== Synopsis

Declared in header `</boost/url/grammar/dec_octet_rule.hpp#L58[boost/url/grammar/dec_octet_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = unsigned char;
----


[#boost-urls-grammar-dec_octet_rule_t-parse]

= Function dec_octet_rule_t::parse



== Synopsis

Declared in header `</boost/url/grammar/dec_octet_rule.hpp#L61[boost/url/grammar/dec_octet_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-dec_octet_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-grammar-dec_octet_rule]

= dec_octet_rule



== Synopsis

Declared in header `</boost/url/grammar/dec_octet_rule.hpp#L69[boost/url/grammar/dec_octet_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar-dec_octet_rule_t[dec_octet_rule_t] dec_octet_rule;
----


[#boost-urls-grammar-literal_rule]

= Class literal_rule



== Synopsis

Declared in header `</boost/url/grammar/literal_rule.hpp#L49[boost/url/grammar/literal_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class literal_rule;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-literal_rule-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-literal_rule-2constructor[`pass:v[literal_rule]`] |

|xref:boost-urls-grammar-literal_rule-parse[`pass:v[parse]`] |

|===



[#boost-urls-grammar-literal_rule-value_type]

= literal_rule::value_type



== Synopsis

Declared in header `</boost/url/grammar/literal_rule.hpp#L65[boost/url/grammar/literal_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = string_view;
----


[#boost-urls-grammar-literal_rule-2constructor]

= Function literal_rule::literal_rule



== Synopsis

Declared in header `</boost/url/grammar/literal_rule.hpp#L67[boost/url/grammar/literal_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
literal_rule(const char* s) noexcept;
----


[#boost-urls-grammar-literal_rule-parse]

= Function literal_rule::parse



== Synopsis

Declared in header `</boost/url/grammar/literal_rule.hpp#L77[boost/url/grammar/literal_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-grammar-literal_rule-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-sub_delim_chars]

= sub_delim_chars

pass:v,q[The sub-delims character set]


== Synopsis

Declared in header `</boost/url/rfc/sub_delim_chars.hpp#L45[boost/url/rfc/sub_delim_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar[grammar]::xref:boost-urls-grammar-lut_chars[lut_chars] sub_delim_chars;
----

== Description


=== Example
pass:v,q[Character sets are used with rules and] pass:v,q[the functions]
xref:boost-urls-grammar-find_if[grammar::find_if]
pass:v,q[and]
xref:boost-urls-grammar-find_if_not[grammar::find_if_not.]
[,cpp]
----
system::result< decode_view > = grammar::parse( "Program%20Files", pct_encoded_rule( sub_delim_chars ) );
----

=== BNF
[,cpp]
----
sub-delims    = "!" / "$" / "&" / "'" / "(" / ")"
              / "*" / "+" / "," / ";" / "="
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-2.2[2.2. Reserved Characters (rfc3986)]



[#boost-urls-unreserved_chars]

= unreserved_chars

pass:v,q[The unreserved character set]


== Synopsis

Declared in header `</boost/url/rfc/unreserved_chars.hpp#L44[boost/url/rfc/unreserved_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-grammar[grammar]::xref:boost-urls-grammar-lut_chars[lut_chars] unreserved_chars;
----

== Description


=== Example
pass:v,q[Character sets are used with rules and] pass:v,q[the functions]
xref:boost-urls-grammar-find_if[grammar::find_if]
pass:v,q[and]
xref:boost-urls-grammar-find_if_not[grammar::find_if_not.]
[,cpp]
----
system::result< decode_view > rv = grammar::parse( "Program%20Files", pct_encoded_rule( unreserved_chars ) );
----

=== BNF
[,cpp]
----
unreserved    = ALPHA / DIGIT / "-" / "." / "_" / "~"
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-2.3[2.3. Unreserved Characters (rfc3986)]



[#boost-urls-pchars]

= pchars

pass:v,q[The path character set]


== Synopsis

Declared in header `</boost/url/rfc/pchars.hpp#L45[boost/url/rfc/pchars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar[grammar]::xref:boost-urls-grammar-lut_chars[lut_chars] pchars;
----

== Description


=== Example
pass:v,q[Character sets are used with rules and] pass:v,q[the functions]
xref:boost-urls-grammar-find_if[grammar::find_if]
pass:v,q[and]
xref:boost-urls-grammar-find_if_not[grammar::find_if_not.]
[,cpp]
----
system::result< decode_view > rv = grammar::parse( "Program%20Files", pchars );
----

=== BNF
[,cpp]
----
pchar         = unreserved / pct-encoded / sub-delims / ":" / "@"
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]



[#boost-urls-encoding_opts]

= Class encoding_opts

pass:v,q[Percent-encoding options]


== Synopsis

Declared in header `</boost/url/encoding_opts.hpp#L31[boost/url/encoding_opts.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct encoding_opts;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-encoding_opts-2constructor[`pass:v[encoding_opts]`] |

|===
==  Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-encoding_opts-disallow_null[`pass:v[disallow_null]`] |
pass:v,q[True if nulls are not allowed]

|xref:boost-urls-encoding_opts-lower_case[`pass:v[lower_case]`] |
pass:v,q[True if hexadecimal digits are emitted as lower case]

|xref:boost-urls-encoding_opts-space_as_plus[`pass:v[space_as_plus]`] |
pass:v,q[True if spaces encode to and from plus signs]

|===

== Description

pass:v,q[These options are used to customize] pass:v,q[the behavior of algorithms which use]
pass:v,q[percent escapes, such as encoding]
pass:v,q[or decoding.]




[#boost-urls-encoding_opts-space_as_plus]

= encoding_opts::space_as_plus

pass:v,q[True if spaces encode to and from plus signs]


== Synopsis

Declared in header `</boost/url/encoding_opts.hpp#L48[boost/url/encoding_opts.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool space_as_plus;
----

== Description

pass:v,q[This option controls whether or not] pass:v,q[the PLUS character ("+") is used to]
pass:v,q[represent the SP character (" ") when]
pass:v,q[encoding or decoding.]
pass:v,q[Although not prescribed by the RFC, plus]
pass:v,q[signs are commonly treated as spaces upon]
pass:v,q[decoding when used in the query of URLs]
pass:v,q[using well known schemes such as HTTP.]

=== Specification

* link:https://www.w3.org/TR/html401/interact/forms.html#h-17.13.4.1[            application/x-www-form-urlencoded (w3.org)]



[#boost-urls-encoding_opts-lower_case]

= encoding_opts::lower_case

pass:v,q[True if hexadecimal digits are emitted as lower case]


== Synopsis

Declared in header `</boost/url/encoding_opts.hpp#L57[boost/url/encoding_opts.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool lower_case;
----

== Description

pass:v,q[By default, percent-encoding algorithms] pass:v,q[emit hexadecimal digits A through F as]
pass:v,q[uppercase letters. When this option is]
pass:v,q[`true`, lowercase letters are used.]



[#boost-urls-encoding_opts-disallow_null]

= encoding_opts::disallow_null

pass:v,q[True if nulls are not allowed]


== Synopsis

Declared in header `</boost/url/encoding_opts.hpp#L68[boost/url/encoding_opts.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool disallow_null;
----

== Description

pass:v,q[Normally all possible character values] pass:v,q[(from 0 to 255) are allowed, with reserved]
pass:v,q[characters being replaced with escapes]
pass:v,q[upon encoding. When this option is true,]
pass:v,q[attempting to decode a null will result]
pass:v,q[in an error.]



[#boost-urls-encoding_opts-2constructor]

= Function encoding_opts::encoding_opts



== Synopsis

Declared in header `</boost/url/encoding_opts.hpp#L71[boost/url/encoding_opts.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
encoding_opts(
    bool space_as_plus_ = false,
    bool lower_case_ = false,
    bool disallow_null_ = false) noexcept;
----


[#boost-urls-error_types]

= Namespace error_types

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-error_types-error_category[`pass:v[error_category]`] |
pass:v,q[The type of error category used by the library]

|xref:boost-urls-error_types-error_code[`pass:v[error_code]`] |
pass:v,q[The type of error code used by the library]

|xref:boost-urls-error_types-error_condition[`pass:v[error_condition]`] |
pass:v,q[The type of error condition used by the library]

|xref:boost-urls-error_types-result[`pass:v[result]`] |
pass:v,q[The type of result returned by library functions]

|xref:boost-urls-error_types-system_error[`pass:v[system_error]`] |
pass:v,q[The type of system error thrown by the library]

|===

[#boost-urls-error_types-error_category]

= error_category

pass:v,q[The type of error category used by the library]


== Synopsis

Declared in header `</boost/url/error_types.hpp#L43[boost/url/error_types.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using error_category = error_category;
----

== Description

[NOTE]
pass:v,q[This alias is no longer supported and] pass:v,q[should not be used in new code. Please use]
pass:v,q[`system::error_category` instead.]
pass:v,q[This alias is included for backwards]
pass:v,q[compatibility with earlier versions of the]
pass:v,q[library.]
pass:v,q[However, it will be removed in future releases,]
pass:v,q[and using it in new code is not recommended.]
pass:v,q[Please use the updated version instead to]
pass:v,q[ensure compatibility with future versions of]
pass:v,q[the library.]



[#boost-urls-error_types-error_code]

= error_code

pass:v,q[The type of error code used by the library]


== Synopsis

Declared in header `</boost/url/error_types.hpp#L65[boost/url/error_types.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using error_code = error_code;
----

== Description

[NOTE]
pass:v,q[This alias is no longer supported and] pass:v,q[should not be used in new code. Please use]
pass:v,q[`system::error_code` instead.]
pass:v,q[This alias is included for backwards]
pass:v,q[compatibility with earlier versions of the]
pass:v,q[library.]
pass:v,q[However, it will be removed in future releases,]
pass:v,q[and using it in new code is not recommended.]
pass:v,q[Please use the updated version instead to]
pass:v,q[ensure compatibility with future versions of]
pass:v,q[the library.]



[#boost-urls-error_types-error_condition]

= error_condition

pass:v,q[The type of error condition used by the library]


== Synopsis

Declared in header `</boost/url/error_types.hpp#L87[boost/url/error_types.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using error_condition = error_condition;
----

== Description

[NOTE]
pass:v,q[This alias is no longer supported and] pass:v,q[should not be used in new code. Please use]
pass:v,q[`system::error_condition` instead.]
pass:v,q[This alias is included for backwards]
pass:v,q[compatibility with earlier versions of the]
pass:v,q[library.]
pass:v,q[However, it will be removed in future releases,]
pass:v,q[and using it in new code is not recommended.]
pass:v,q[Please use the updated version instead to]
pass:v,q[ensure compatibility with future versions of]
pass:v,q[the library.]



[#boost-urls-error_types-system_error]

= system_error

pass:v,q[The type of system error thrown by the library]


== Synopsis

Declared in header `</boost/url/error_types.hpp#L109[boost/url/error_types.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using system_error = system_error;
----

== Description

[NOTE]
pass:v,q[This alias is no longer supported and] pass:v,q[should not be used in new code. Please use]
pass:v,q[`system::system_error` instead.]
pass:v,q[This alias is included for backwards]
pass:v,q[compatibility with earlier versions of the]
pass:v,q[library.]
pass:v,q[However, it will be removed in future releases,]
pass:v,q[and using it in new code is not recommended.]
pass:v,q[Please use the updated version instead to]
pass:v,q[ensure compatibility with future versions of]
pass:v,q[the library.]



[#boost-urls-error_types-result]

= result

pass:v,q[The type of result returned by library functions]


== Synopsis

Declared in header `</boost/url/error_types.hpp#L280[boost/url/error_types.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
using result = result<T, error_code>;
----

== Description

[NOTE]
pass:v,q[This alias is no longer supported and] pass:v,q[should not be used in new code. Please use]
pass:v,q[`system::result` instead.]
pass:v,q[This alias is included for backwards]
pass:v,q[compatibility with earlier versions of the]
pass:v,q[library.]
pass:v,q[However, it will be removed in future releases,]
pass:v,q[and using it in new code is not recommended.]
pass:v,q[Please use the updated version instead to]
pass:v,q[ensure compatibility with future versions of]
pass:v,q[the library.]

=== Declaration
[,cpp]
----
template< class T >
class result
{
public:
    //
    // Return true if the result contains an error
    //
    constexpr bool has_error() const noexcept;

    //
    // Return the error
    //
    constexpr system::error_code error() const noexcept;

    //
    // Return true if the result contains a value
    //
    constexpr bool has_value() const noexcept;
    constexpr explicit operator bool() const noexcept;

    //
    // Return the value, or throw an exception
    //
    constexpr T& value();
    constexpr T const& value() const;

    // Return the value.
    // Precondition: has_value()==true
    //
    constexpr T& operator*() noexcept;
    constexpr T* operator->() noexcept;
    constexpr T const& operator*() const noexcept;
    constexpr T const* operator->() const noexcept;

    ...more
----

=== Usage
pass:v,q[Given the function]
xref:boost-urls-parse_uri[parse_uri]
pass:v,q[with this signature:]
[,cpp]
----
system::result< url_view > parse_uri( core::string_view s ) noexcept;
----
pass:v,q[The following statement captures the value in a]
pass:v,q[variable upon success, otherwise throws:]
[,cpp]
----
url_view u = parse_uri( "http://example.com/path/to/file.txt" ).value();
----
pass:v,q[This statement captures the result in a local]
pass:v,q[variable and inspects the error condition:]
[,cpp]
----
system::result< url_view > rv = parse_uri( "http://example.com/path/to/file.txt" );

if(! rv )
    std::cout << rv.error();
else
    std::cout << *rv;
----

* link:https://boost.org/libs/system/doc/html/system.html#ref_resultt_e[`boost::system::result`]



[#boost-urls-string_token]

= Namespace string_token

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-append_to_t[`pass:v[append_to_t]`] |

|xref:boost-urls-string_token-arg[`pass:v[arg]`] |
pass:v,q[Base class for string tokens, and algorithm parameters]

|xref:boost-urls-string_token-assign_to_t[`pass:v[assign_to_t]`] |

|xref:boost-urls-string_token-is_token-0a[`pass:v[is_token]`] |

|xref:boost-urls-string_token-is_token-0b[`pass:v[is_token<T, void_t<decltype(std::declval<T&>().prepare(
                std::declval<std::size_t>())), decltype(std::declval<T&>().result())>>]`] |

|xref:boost-urls-string_token-preserve_size_t[`pass:v[preserve_size_t]`] |

|xref:boost-urls-string_token-return_string[`pass:v[return_string]`] |

|===
== Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-append_to[`pass:v[append_to]`] |

|xref:boost-urls-string_token-assign_to[`pass:v[assign_to]`] |

|xref:boost-urls-string_token-preserve_size[`pass:v[preserve_size]`] |

|===

[#boost-urls-string_token-arg]

= Class arg

pass:v,q[Base class for string tokens, and algorithm parameters]


== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L49[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct arg;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-arg-2constructor[`pass:v[arg]`] |
|xref:boost-urls-string_token-arg-operator_assign[`pass:v[operator=]`] |
|xref:boost-urls-string_token-arg-prepare[`pass:v[prepare]`] |
pass:v,q[Return a modifiable character buffer]

|xref:boost-urls-string_token-arg-2destructor[`pass:v[~arg]`] |

|===

== Description

pass:v,q[This abstract interface provides a means] pass:v,q[for an algorithm to generically obtain a]
pass:v,q[modifiable, contiguous character buffer]
pass:v,q[of prescribed size. As the author of an]
pass:v,q[algorithm simply declare an rvalue]
pass:v,q[reference as a parameter type.]
pass:v,q[Instances of this type are intended only]
pass:v,q[to be used once and then destroyed.]

=== Example
pass:v,q[The declared function accepts any]
pass:v,q[temporary instance of `arg` to be]
pass:v,q[used for writing:]
[,cpp]
----
void algorithm( string_token::arg&& dest );
----
pass:v,q[To implement the interface for your type]
pass:v,q[or use-case, derive from the class and]
pass:v,q[implement the prepare function.]




[#boost-urls-string_token-arg-prepare]

= Function arg::prepare

pass:v,q[Return a modifiable character buffer]


== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L68[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
char*
prepare(size_t n) = 0;
----

== Description

pass:v,q[This function attempts to obtain a] pass:v,q[character buffer with space for at]
pass:v,q[least `n` characters. Upon success,]
pass:v,q[a pointer to the beginning of the]
pass:v,q[buffer is returned. Ownership is not]
pass:v,q[transferred; the caller should not]
pass:v,q[attempt to free the storage. The]
pass:v,q[buffer shall remain valid until]
pass:v,q[`this` is destroyed.]
[NOTE]
pass:v,q[This function may only be called once.]
pass:v,q[After invoking the function, the only]
pass:v,q[valid operation is destruction.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *n*
| `size_t`

|===




[#boost-urls-string_token-arg-2destructor]

= Function arg::~arg



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L71[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
~arg() = default;
----


[#boost-urls-string_token-arg-2constructor]

= Overload set arg::arg

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
arg() = default;
  xref:boost-urls-string_token-arg-2constructor-01[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
arg(xref:boost-urls-string_token-arg[arg]&&) = default;
  xref:boost-urls-string_token-arg-2constructor-0c[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
arg(const xref:boost-urls-string_token-arg[arg]&) = delete;
  xref:boost-urls-string_token-arg-2constructor-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-string_token-arg-operator_assign]

= Overload set arg::operator=

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-arg[arg]&
operator=(xref:boost-urls-string_token-arg[arg]&&) = delete;
  xref:boost-urls-string_token-arg-operator_assign-0f[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-arg[arg]&
operator=(const xref:boost-urls-string_token-arg[arg]&) = delete;
  xref:boost-urls-string_token-arg-operator_assign-01[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-string_token-is_token-0a]

= Class is_token



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L88[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class T,
    class = void>
struct is_token
    : xref:std[std]::xref:std-false_type[false_type];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-type[`pass:v[type]`] |

|xref:std-integral_constant-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-2conversion[`pass:v[operator std::integral_constant::value_type]`] |

|xref:std-integral_constant-operator_call[`pass:v[operator()]`] |

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-value[`pass:v[value]`] |

|===



[#boost-urls-string_token-is_token-0b]

= Class is_token



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L91[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
struct xref:boost-urls-string_token-is_token-0a[is_token]<T, xref:boost-urls-void_t[void_t]<decltype(std::declval<T&>().prepare(
                std::declval<std::size_t>())), decltype(std::declval<T&>().result())>>
    : xref:std[std]::xref:std-integral_constant[integral_constant]<bool, std::is_convertible<decltype(std::declval<T &>().result()), typename T::result_type>::value && std::is_same<decltype(std::declval<T &>().prepare(0)), char *>::value && std::is_base_of<arg, T>::value && std::is_convertible<const volatile T *, const volatile arg *>::value>;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-type[`pass:v[type]`] |

|xref:std-integral_constant-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-2conversion[`pass:v[operator std::integral_constant::value_type]`] |

|xref:std-integral_constant-operator_call[`pass:v[operator()]`] |

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-value[`pass:v[value]`] |

|===



[#boost-urls-string_token-return_string]

= Class return_string



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L117[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct return_string
    : xref:boost-urls-string_token-arg[arg];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-return_string-result_type[`pass:v[result_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-arg-operator_assign[`pass:v[operator=]`] |
|xref:boost-urls-string_token-arg-prepare[`pass:v[prepare]`] |
pass:v,q[Return a modifiable character buffer]

|xref:boost-urls-string_token-return_string-result[`pass:v[result]`] |

|===



[#boost-urls-string_token-return_string-result_type]

= return_string::result_type



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L120[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using result_type = string;
----


[#boost-urls-string_token-return_string-prepare]

= Function return_string::prepare



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L122[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
char*
prepare(size_t n) override;
----


[#boost-urls-string_token-return_string-result]

= Function return_string::result



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L129[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-return_string-result_type[result_type]
result() noexcept;
----


[#boost-urls-string_token-append_to_t]

= Class append_to_t



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L156[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Alloc>
struct append_to_t
    : xref:boost-urls-string_token-arg[arg];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-append_to_t-result_type[`pass:v[result_type]`] |

|xref:boost-urls-string_token-append_to_t-string_type[`pass:v[string_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-append_to_t-2constructor[`pass:v[append_to_t]`] |

|xref:boost-urls-string_token-arg-operator_assign[`pass:v[operator=]`] |
|xref:boost-urls-string_token-arg-prepare[`pass:v[prepare]`] |
pass:v,q[Return a modifiable character buffer]

|xref:boost-urls-string_token-append_to_t-result[`pass:v[result]`] |

|===



[#boost-urls-string_token-append_to_t-string_type]

= append_to_t::string_type



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L159[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using string_type = basic_string<char, char_traits<char>, Alloc>;
----


[#boost-urls-string_token-append_to_t-result_type]

= append_to_t::result_type



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L163[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using result_type = xref:boost-urls-string_token-append_to_t-string_type[string_type]&;
----


[#boost-urls-string_token-append_to_t-2constructor]

= Function append_to_t::append_to_t



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L165[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
append_to_t(xref:boost-urls-string_token-append_to_t-string_type[string_type]& s) noexcept;
----


[#boost-urls-string_token-append_to_t-prepare]

= Function append_to_t::prepare



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L172[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
char*
prepare(size_t n) override;
----


[#boost-urls-string_token-append_to_t-result]

= Function append_to_t::result



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L182[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-append_to_t-result_type[result_type]
result() noexcept;
----


[#boost-urls-string_token-append_to]

= Function append_to



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L195[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Alloc = allocator<char>>
xref:boost-urls-string_token-append_to_t[append_to_t]<Alloc>
append_to(basic_string<char, char_traits<char>, Alloc>& s);
----


[#boost-urls-string_token-assign_to_t]

= Class assign_to_t



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L222[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Alloc>
struct assign_to_t
    : xref:boost-urls-string_token-arg[arg];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-assign_to_t-result_type[`pass:v[result_type]`] |

|xref:boost-urls-string_token-assign_to_t-string_type[`pass:v[string_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-assign_to_t-2constructor[`pass:v[assign_to_t]`] |

|xref:boost-urls-string_token-arg-operator_assign[`pass:v[operator=]`] |
|xref:boost-urls-string_token-arg-prepare[`pass:v[prepare]`] |
pass:v,q[Return a modifiable character buffer]

|xref:boost-urls-string_token-assign_to_t-result[`pass:v[result]`] |

|===



[#boost-urls-string_token-assign_to_t-string_type]

= assign_to_t::string_type



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L225[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using string_type = basic_string<char, char_traits<char>, Alloc>;
----


[#boost-urls-string_token-assign_to_t-result_type]

= assign_to_t::result_type



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L229[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using result_type = xref:boost-urls-string_token-assign_to_t-string_type[string_type]&;
----


[#boost-urls-string_token-assign_to_t-2constructor]

= Function assign_to_t::assign_to_t



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L231[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
assign_to_t(xref:boost-urls-string_token-assign_to_t-string_type[string_type]& s) noexcept;
----


[#boost-urls-string_token-assign_to_t-prepare]

= Function assign_to_t::prepare



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L238[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
char*
prepare(size_t n) override;
----


[#boost-urls-string_token-assign_to_t-result]

= Function assign_to_t::result



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L245[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-assign_to_t-result_type[result_type]
result() noexcept;
----


[#boost-urls-string_token-assign_to]

= Function assign_to



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L258[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Alloc = allocator<char>>
xref:boost-urls-string_token-assign_to_t[assign_to_t]<Alloc>
assign_to(basic_string<char, char_traits<char>, Alloc>& s);
----


[#boost-urls-string_token-preserve_size_t]

= Class preserve_size_t



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L285[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Alloc>
struct preserve_size_t
    : xref:boost-urls-string_token-arg[arg];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-preserve_size_t-result_type[`pass:v[result_type]`] |

|xref:boost-urls-string_token-preserve_size_t-string_type[`pass:v[string_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-string_token-arg-operator_assign[`pass:v[operator=]`] |
|xref:boost-urls-string_token-arg-prepare[`pass:v[prepare]`] |
pass:v,q[Return a modifiable character buffer]

|xref:boost-urls-string_token-preserve_size_t-2constructor[`pass:v[preserve_size_t]`] |

|xref:boost-urls-string_token-preserve_size_t-result[`pass:v[result]`] |

|===



[#boost-urls-string_token-preserve_size_t-result_type]

= preserve_size_t::result_type



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L288[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using result_type = string_view;
----


[#boost-urls-string_token-preserve_size_t-string_type]

= preserve_size_t::string_type



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L290[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using string_type = basic_string<char, char_traits<char>, Alloc>;
----


[#boost-urls-string_token-preserve_size_t-2constructor]

= Function preserve_size_t::preserve_size_t



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L294[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
preserve_size_t(xref:boost-urls-string_token-preserve_size_t-string_type[string_type]& s) noexcept;
----


[#boost-urls-string_token-preserve_size_t-prepare]

= Function preserve_size_t::prepare



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L301[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
char*
prepare(size_t n) override;
----


[#boost-urls-string_token-preserve_size_t-result]

= Function preserve_size_t::result



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L312[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-preserve_size_t-result_type[result_type]
result() noexcept;
----


[#boost-urls-string_token-preserve_size]

= Function preserve_size



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L327[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Alloc = allocator<char>>
xref:boost-urls-string_token-preserve_size_t[preserve_size_t]<Alloc>
preserve_size(basic_string<char, char_traits<char>, Alloc>& s);
----


[#boost-urls-decode_view]

= Class decode_view

pass:v,q[A reference to a valid, percent-encoded string]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L87[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class decode_view;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-decode_view-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-decode_view-iterator[iterator]

|xref:boost-urls-decode_view-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-decode_view-difference_type[`pass:v[difference_type]`] |
pass:v,q[The signed integer type]

|xref:boost-urls-decode_view-iterator[`pass:v[iterator]`] |

|xref:boost-urls-decode_view-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-decode_view-size_type[`pass:v[size_type]`] |
pass:v,q[The unsigned integer type]

|xref:boost-urls-decode_view-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-decode_view-back[`pass:v[back]`] |
pass:v,q[Return the last character]

|xref:boost-urls-decode_view-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-decode_view-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing to another string]

|xref:boost-urls-decode_view-2constructor[`pass:v[decode_view]`] |
pass:v,q[Constructor]

|xref:boost-urls-decode_view-empty[`pass:v[empty]`] |
pass:v,q[Return true if the string is empty]

|xref:boost-urls-decode_view-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-decode_view-ends_with[`pass:v[ends_with]`] |
pass:v,q[Checks if the string ends with the given prefix]

|xref:boost-urls-decode_view-find[`pass:v[find]`] |
pass:v,q[Finds the first occurrence of character in this view]

|xref:boost-urls-decode_view-front[`pass:v[front]`] |
pass:v,q[Return the first character]

|xref:boost-urls-decode_view-options[`pass:v[options]`] |
pass:v,q[Return the decoding options]

|xref:boost-urls-decode_view-remove_prefix[`pass:v[remove_prefix]`] |
pass:v,q[Remove the first characters]

|xref:boost-urls-decode_view-remove_suffix[`pass:v[remove_suffix]`] |
pass:v,q[Remove the last characters]

|xref:boost-urls-decode_view-rfind[`pass:v[rfind]`] |
pass:v,q[Finds the first occurrence of character in this view]

|xref:boost-urls-decode_view-size[`pass:v[size]`] |
pass:v,q[Return the number of decoded characters]

|xref:boost-urls-decode_view-starts_with[`pass:v[starts_with]`] |
pass:v,q[Checks if the string begins with the given prefix]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-decode_view-8friend-04[`pass:v[operator!=]`] |

|xref:boost-urls-decode_view-8friend-0e[`pass:v[operator<]`] |

|xref:boost-urls-decode_view-8friend-0a1[`pass:v[operator<<]`] |

|xref:boost-urls-decode_view-8friend-0c[`pass:v[operator<=]`] |

|xref:boost-urls-decode_view-8friend-0aa[`pass:v[operator==]`] |

|xref:boost-urls-decode_view-8friend-07[`pass:v[operator>]`] |

|xref:boost-urls-decode_view-8friend-01[`pass:v[operator>=]`] |

|===

== Description

pass:v,q[These views reference strings in parts of URLs] pass:v,q[or other components that are percent-encoded.]
pass:v,q[The special characters (those not in the]
pass:v,q[allowed character set) are stored as three]
pass:v,q[character escapes that consist of a percent]
pass:v,q[sign ('%%') followed by a two-digit hexadecimal]
pass:v,q[number of the corresponding unescaped character]
pass:v,q[code, which may be part of a UTF-8 code point]
pass:v,q[depending on the context.]
pass:v,q[The view refers to the original character]
pass:v,q[buffer and only decodes escaped sequences when]
pass:v,q[needed. In particular these operations perform]
pass:v,q[percent-decoding automatically without the]
pass:v,q[need to allocate memory:]

* pass:v,q[Iteration of the string]

* pass:v,q[Accessing the encoded character buffer]

* pass:v,q[Comparison to encoded or plain strings]
pass:v,q[These objects can only be constructed from]
pass:v,q[strings that have a valid percent-encoding,]
pass:v,q[otherwise construction fails. The caller is]
pass:v,q[responsible for ensuring that the lifetime]
pass:v,q[of the character buffer from which the view]
pass:v,q[is constructed extends unmodified until the]
pass:v,q[view is no longer accessed.]

=== Operators
pass:v,q[The following operators are supported between]
xref:boost-urls-decode_view-2constructor-07[decode_view]
pass:v,q[and any object that is convertible]
pass:v,q[to `core::string_view`]
[,cpp]
----
bool operator==( decode_view, decode_view ) noexcept;
bool operator!=( decode_view, decode_view ) noexcept;
bool operator<=( decode_view, decode_view ) noexcept;
bool operator< ( decode_view, decode_view ) noexcept;
bool operator> ( decode_view, decode_view ) noexcept;
bool operator>=( decode_view, decode_view ) noexcept;
----




[#boost-urls-decode_view-value_type]

= decode_view::value_type

pass:v,q[The value type]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L113[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = char;
----


[#boost-urls-decode_view-reference]

= decode_view::reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L117[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = char;
----


[#boost-urls-decode_view-const_reference]

= decode_view::const_reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L120[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_reference = char;
----


[#boost-urls-decode_view-size_type]

= decode_view::size_type

pass:v,q[The unsigned integer type]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L124[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using size_type = size_t;
----


[#boost-urls-decode_view-difference_type]

= decode_view::difference_type

pass:v,q[The signed integer type]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L128[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-decode_view-iterator]

= Class decode_view::iterator



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L19[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class iterator;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-decode_view-iterator-const_reference[`pass:v[const_reference]`] |

|xref:boost-urls-decode_view-iterator-difference_type[`pass:v[difference_type]`] |

|xref:boost-urls-decode_view-iterator-iterator_category[`pass:v[iterator_category]`] |

|xref:boost-urls-decode_view-iterator-pointer[`pass:v[pointer]`] |

|xref:boost-urls-decode_view-iterator-reference[`pass:v[reference]`] |

|xref:boost-urls-decode_view-iterator-size_type[`pass:v[size_type]`] |

|xref:boost-urls-decode_view-iterator-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-decode_view-iterator-base[`pass:v[base]`] |

|xref:boost-urls-decode_view-iterator-2constructor[`pass:v[iterator]`] |
|xref:boost-urls-decode_view-iterator-operator_not_eq[`pass:v[operator!=]`] |

|xref:boost-urls-decode_view-iterator-operator_star[`pass:v[operator*]`] |

|xref:boost-urls-decode_view-iterator-operator_inc[`pass:v[operator++]`] |
|xref:boost-urls-decode_view-iterator-operator_dec[`pass:v[operator--]`] |
|xref:boost-urls-decode_view-iterator-operator_assign[`pass:v[operator=]`] |

|xref:boost-urls-decode_view-iterator-operator_eq[`pass:v[operator==]`] |

|===



[#boost-urls-decode_view-iterator-value_type]

= decode_view::iterator::value_type



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L49[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = char;
----


[#boost-urls-decode_view-iterator-reference]

= decode_view::iterator::reference



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L50[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = char;
----


[#boost-urls-decode_view-iterator-pointer]

= decode_view::iterator::pointer



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L51[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using pointer = const void*;
----


[#boost-urls-decode_view-iterator-const_reference]

= decode_view::iterator::const_reference



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L52[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_reference = char;
----


[#boost-urls-decode_view-iterator-size_type]

= decode_view::iterator::size_type



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L53[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using size_type = size_t;
----


[#boost-urls-decode_view-iterator-difference_type]

= decode_view::iterator::difference_type



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L54[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-decode_view-iterator-iterator_category]

= decode_view::iterator::iterator_category



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L55[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using iterator_category = bidirectional_iterator_tag;
----


[#boost-urls-decode_view-iterator-2constructor]

= Overload set decode_view::iterator::iterator

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator() = default;
  xref:boost-urls-decode_view-iterator-2constructor-05[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-decode_view-iterator[iterator]&) = default;
  xref:boost-urls-decode_view-iterator-2constructor-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-decode_view-iterator-operator_assign]

= Function decode_view::iterator::operator=



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L62[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-decode_view-iterator[iterator]&
operator=(const xref:boost-urls-decode_view-iterator[iterator]&) = default;
----


[#boost-urls-decode_view-iterator-operator_star]

= Function decode_view::iterator::operator*



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L66[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator-reference[reference]
operator*() const noexcept;
----


[#boost-urls-decode_view-iterator-operator_inc]

= Overload set decode_view::iterator::operator++

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]&
operator++() noexcept;
  xref:boost-urls-decode_view-iterator-operator_inc-0a[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]
operator++(int) noexcept;
  xref:boost-urls-decode_view-iterator-operator_inc-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-decode_view-iterator-operator_dec]

= Overload set decode_view::iterator::operator--

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]&
operator--() noexcept;
  xref:boost-urls-decode_view-iterator-operator_dec-04[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]
operator--(int) noexcept;
  xref:boost-urls-decode_view-iterator-operator_dec-0a[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-decode_view-iterator-base]

= Function decode_view::iterator::base



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L108[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
base();
----


[#boost-urls-decode_view-iterator-operator_eq]

= Function decode_view::iterator::operator==



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L114[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(const xref:boost-urls-decode_view-iterator[iterator]& other) const noexcept;
----


[#boost-urls-decode_view-iterator-operator_not_eq]

= Function decode_view::iterator::operator!=



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L121[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(const xref:boost-urls-decode_view-iterator[iterator]& other) const noexcept;
----


[#boost-urls-decode_view-const_iterator]

= decode_view::const_iterator

xref:boost-urls-decode_view-iterator[iterator]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L145[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_iterator = xref:boost-urls-decode_view-iterator[iterator];
----


[#boost-urls-decode_view-2constructor]

= Overload set decode_view::decode_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
decode_view() noexcept = default;
  xref:boost-urls-decode_view-2constructor-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
decode_view(
    xref:boost-urls-pct_string_view[pct_string_view] s,
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {}) noexcept;
  xref:boost-urls-decode_view-2constructor-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-decode_view-empty]

= Function decode_view::empty

pass:v,q[Return true if the string is empty]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L239[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "" ).empty() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-decode_view-size]

= Function decode_view::size

pass:v,q[Return the number of decoded characters]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L263[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-size_type[size_type]
size() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "Program%20Files" ).size() == 13 );
----

=== Effects
[,cpp]
----
return std::distance( this->begin(), this->end() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_type` 





[#boost-urls-decode_view-begin]

= Function decode_view::begin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L282[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]
begin() const noexcept;
----

== Description


=== Example
[,cpp]
----
auto it = this->begin();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-decode_view-end]

= Function decode_view::end

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L298[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]
end() const noexcept;
----

== Description


=== Example
[,cpp]
----
auto it = this->end();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-decode_view-front]

= Function decode_view::front

pass:v,q[Return the first character]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L319[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-reference[reference]
front() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "Program%20Files" ).front() == 'P' );
----

=== Preconditions
[,cpp]
----
not this->empty()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `reference` 





[#boost-urls-decode_view-back]

= Function decode_view::back

pass:v,q[Return the last character]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L340[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-reference[reference]
back() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "Program%20Files" ).back() == 's' );
----

=== Preconditions
[,cpp]
----
not this->empty()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `reference` 





[#boost-urls-decode_view-starts_with]

= Overload set decode_view::starts_with

== Members


pass:v,q[Checks if the string begins with the given prefix]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
starts_with(string_view s) const noexcept;
  xref:boost-urls-decode_view-starts_with-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Checks if the string begins with the given prefix]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
starts_with(char ch) const noexcept;
  xref:boost-urls-decode_view-starts_with-0b[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-decode_view-ends_with]

= Overload set decode_view::ends_with

== Members


pass:v,q[Checks if the string ends with the given prefix]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
ends_with(string_view s) const noexcept;
  xref:boost-urls-decode_view-ends_with-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Checks if the string ends with the given prefix]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
ends_with(char ch) const noexcept;
  xref:boost-urls-decode_view-ends_with-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-decode_view-find]

= Function decode_view::find

pass:v,q[Finds the first occurrence of character in this view]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L420[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-const_iterator[const_iterator]
find(char ch) const noexcept;
----

== Description


=== Complexity
pass:v,q[Linear.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `const_iterator` 


== Parameters

|===
| Name | Type 

| *ch*
| `char`

|===




[#boost-urls-decode_view-rfind]

= Function decode_view::rfind

pass:v,q[Finds the first occurrence of character in this view]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L432[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-const_iterator[const_iterator]
rfind(char ch) const noexcept;
----

== Description


=== Complexity
pass:v,q[Linear.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `const_iterator` 


== Parameters

|===
| Name | Type 

| *ch*
| `char`

|===




[#boost-urls-decode_view-remove_prefix]

= Function decode_view::remove_prefix

pass:v,q[Remove the first characters]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L453[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
remove_prefix(xref:boost-urls-decode_view-size_type[size_type] n);
----

== Description


=== Example
[,cpp]
----
decode_view d( "Program%20Files" );
d.remove_prefix( 8 );
assert( d == "Files" );
----

=== Preconditions
[,cpp]
----
not this->empty()
----

=== Complexity
pass:v,q[Linear.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *n*
| `size_type`

|===




[#boost-urls-decode_view-remove_suffix]

= Function decode_view::remove_suffix

pass:v,q[Remove the last characters]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L474[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
remove_suffix(xref:boost-urls-decode_view-size_type[size_type] n);
----

== Description


=== Example
[,cpp]
----
decode_view d( "Program%20Files" );
d.remove_prefix( 6 );
assert( d == "Program" );
----

=== Preconditions
[,cpp]
----
not this->empty()
----

=== Complexity
pass:v,q[Linear.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *n*
| `size_type`

|===




[#boost-urls-decode_view-options]

= Function decode_view::options

pass:v,q[Return the decoding options]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L479[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-encoding_opts[encoding_opts]
options() const noexcept;
----


[#boost-urls-decode_view-compare]

= Overload set decode_view::compare

== Members


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
int
compare(string_view other) const noexcept;
  xref:boost-urls-decode_view-compare-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing to another string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
int
compare(xref:boost-urls-decode_view[decode_view] other) const noexcept;
  xref:boost-urls-decode_view-compare-01[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-decode_view-8friend-0aa]

= Friend operator==



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L578[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator==(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-decode_view-8friend-04]

= Friend operator!=



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L587[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator!=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-decode_view-8friend-0e]

= Friend operator<



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L596[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-decode_view-8friend-0c]

= Friend operator<=



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L605[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-decode_view-8friend-07]

= Friend operator>



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L614[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-decode_view-8friend-01]

= Friend operator>=



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L623[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
friend
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-decode_view-8friend-0a1]

= Friend operator<<



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L634[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-decode_view[decode_view]& s);
----


[#boost-urls-pct_string_view]

= Class pct_string_view

pass:v,q[A reference to a valid percent-encoded string]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L73[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class pct_string_view
    : public xref:boost-urls-grammar[grammar]::xref:boost-urls-grammar-string_view_base[string_view_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-const_iterator[`pass:v[const_iterator]`] |
pass:v,q[The const iterator type]

|xref:boost-urls-grammar-string_view_base-const_pointer[`pass:v[const_pointer]`] |
pass:v,q[The const pointer type]

|xref:boost-urls-grammar-string_view_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The const reference type]

|xref:boost-urls-grammar-string_view_base-const_reverse_iterator[`pass:v[const_reverse_iterator]`] |
pass:v,q[The const reverse iterator type]

|xref:boost-urls-grammar-string_view_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[The difference type]

|xref:boost-urls-grammar-string_view_base-iterator[`pass:v[iterator]`] |
pass:v,q[The iterator type]

|xref:boost-urls-grammar-string_view_base-pointer[`pass:v[pointer]`] |
pass:v,q[The pointer type]

|xref:boost-urls-grammar-string_view_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-grammar-string_view_base-reverse_iterator[`pass:v[reverse_iterator]`] |
pass:v,q[The reverse iterator type]

|xref:boost-urls-grammar-string_view_base-size_type[`pass:v[size_type]`] |
pass:v,q[The size type]

|xref:boost-urls-grammar-string_view_base-traits_type[`pass:v[traits_type]`] |
pass:v,q[The character traits]

|xref:boost-urls-grammar-string_view_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-at[`pass:v[at]`] |
pass:v,q[Access a character]

|xref:boost-urls-grammar-string_view_base-back[`pass:v[back]`] |
pass:v,q[Return the last character]

|xref:boost-urls-grammar-string_view_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-grammar-string_view_base-cbegin[`pass:v[cbegin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-grammar-string_view_base-cend[`pass:v[cend]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-grammar-string_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing to another string]

|xref:boost-urls-grammar-string_view_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if matching characters are found]

|xref:boost-urls-grammar-string_view_base-copy[`pass:v[copy]`] |
pass:v,q[Copy the characters to another buffer]

|xref:boost-urls-grammar-string_view_base-crbegin[`pass:v[crbegin]`] |

|xref:boost-urls-grammar-string_view_base-crend[`pass:v[crend]`] |

|xref:boost-urls-grammar-string_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the character buffer]

|xref:boost-urls-pct_string_view-decode[`pass:v[decode]`] |
pass:v,q[Return the string with percent-decoding]

|xref:boost-urls-pct_string_view-decoded_size[`pass:v[decoded_size]`] |
pass:v,q[Return the decoded size]

|xref:boost-urls-grammar-string_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the string is empty]

|xref:boost-urls-grammar-string_view_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-grammar-string_view_base-ends_with[`pass:v[ends_with]`] |
pass:v,q[Return true if a matching suffix exists]

|xref:boost-urls-grammar-string_view_base-find[`pass:v[find]`] |
pass:v,q[Return the position of matching characters]

|xref:boost-urls-grammar-string_view_base-find_first_not_of[`pass:v[find_first_not_of]`] |
pass:v,q[Return the position of the first non-match]

|xref:boost-urls-grammar-string_view_base-find_first_of[`pass:v[find_first_of]`] |
pass:v,q[Return the position of the first match]

|xref:boost-urls-grammar-string_view_base-find_last_not_of[`pass:v[find_last_not_of]`] |
pass:v,q[Return the position of the last non-match]

|xref:boost-urls-grammar-string_view_base-find_last_of[`pass:v[find_last_of]`] |
pass:v,q[Return the position of the last match]

|xref:boost-urls-grammar-string_view_base-front[`pass:v[front]`] |
pass:v,q[Return the first character]

|xref:boost-urls-grammar-string_view_base-length[`pass:v[length]`] |
pass:v,q[Return the size]

|xref:boost-urls-grammar-string_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum allowed size]

|xref:boost-urls-grammar-string_view_base-2conversion-06[`pass:v[operator string]`] |
pass:v,q[Conversion]

|xref:boost-urls-grammar-string_view_base-2conversion-0e[`pass:v[operator string_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-pct_string_view-operator_star[`pass:v[operator*]`] |
pass:v,q[Return the string as a range of decoded characters]

|xref:boost-urls-pct_string_view-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-pct_string_view-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-grammar-string_view_base-operator_subs[`pass:v[operator[]]`] |
pass:v,q[Access a character]

|xref:boost-urls-pct_string_view-2constructor[`pass:v[pct_string_view]`] |
pass:v,q[Constructor (deleted)]

pass:v,q[Constructor]

|xref:boost-urls-grammar-string_view_base-rbegin[`pass:v[rbegin]`] |

|xref:boost-urls-grammar-string_view_base-rend[`pass:v[rend]`] |

|xref:boost-urls-grammar-string_view_base-rfind[`pass:v[rfind]`] |
pass:v,q[Return the position of matching characters]

|xref:boost-urls-grammar-string_view_base-size[`pass:v[size]`] |
pass:v,q[Return the size]

|xref:boost-urls-grammar-string_view_base-starts_with[`pass:v[starts_with]`] |
pass:v,q[Return true if a matching prefix exists]

|xref:boost-urls-grammar-string_view_base-substr[`pass:v[substr]`] |
pass:v,q[Return a view to part of the string]

|xref:boost-urls-pct_string_view-swap[`pass:v[swap]`] |
pass:v,q[Swap]

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-npos[`pass:v[npos]`] |
pass:v,q[A constant used to represent "no position"]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-grammar-string_view_base-8friend-09d[`pass:v[hash_value]`] |
pass:v,q[Return the hash of this value]

|xref:boost-urls-pct_string_view-8friend[`pass:v[make_pct_string_view]`] |

|xref:boost-urls-grammar-string_view_base-8friend-017[`pass:v[operator!=]`] |

|xref:boost-urls-grammar-string_view_base-8friend-010[`pass:v[operator<]`] |

|xref:boost-urls-grammar-string_view_base-8friend-00[`pass:v[operator<<]`] |

|xref:boost-urls-grammar-string_view_base-8friend-0c[`pass:v[operator<=]`] |

|xref:boost-urls-grammar-string_view_base-8friend-095[`pass:v[operator==]`] |

|xref:boost-urls-grammar-string_view_base-8friend-0d[`pass:v[operator>]`] |

|xref:boost-urls-grammar-string_view_base-8friend-02[`pass:v[operator>=]`] |

|===

== Description

pass:v,q[Objects of this type behave like a] pass:v,q[`core::string_view` and have the same interface,]
pass:v,q[but offer an additional invariant: they can]
pass:v,q[only be constructed from strings containing]
pass:v,q[valid percent-escapes.]
pass:v,q[Attempting construction from a string]
pass:v,q[containing invalid or malformed percent]
pass:v,q[escapes results in an exception.]

=== Operators
pass:v,q[The following operators are supported between]
xref:boost-urls-pct_string_view-2constructor-00[pct_string_view]
pass:v,q[and any object that is]
pass:v,q[convertible to `core::string_view`]
[,cpp]
----
bool operator==( pct_string_view, pct_string_view ) noexcept;
bool operator!=( pct_string_view, pct_string_view ) noexcept;
bool operator<=( pct_string_view, pct_string_view ) noexcept;
bool operator< ( pct_string_view, pct_string_view ) noexcept;
bool operator> ( pct_string_view, pct_string_view ) noexcept;
bool operator>=( pct_string_view, pct_string_view ) noexcept;
----




[#boost-urls-pct_string_view-2constructor]

= Overload set pct_string_view::pct_string_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
pct_string_view() = default;
  xref:boost-urls-pct_string_view-2constructor-00[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
pct_string_view(const xref:boost-urls-pct_string_view[pct_string_view]& other) = default;
  xref:boost-urls-pct_string_view-2constructor-07[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class String,
    class = enable_if<std::is_convertible<String, core::string_view>::value>::type>
pct_string_view(const String& s);
  xref:boost-urls-pct_string_view-2constructor-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor (deleted)]


[source,cpp,subs="verbatim,macros,-callouts"]
----
pct_string_view(nullptr_t) = delete;
  xref:boost-urls-pct_string_view-2constructor-0f[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
pct_string_view(
    const char* s,
    size_t len);
  xref:boost-urls-pct_string_view-2constructor-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
pct_string_view(string_view s);
  xref:boost-urls-pct_string_view-2constructor-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-pct_string_view-operator_assign]

= Function pct_string_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L263[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-pct_string_view[pct_string_view]&
operator=(const xref:boost-urls-pct_string_view[pct_string_view]& other) = default;
----

== Description

pass:v,q[The copy references the same] pass:v,q[underlying character buffer.] pass:v,q[Ownership is not transferred.]

=== Postconditions
[,cpp]
----
this->data() == other.data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== other The string to copy.



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-pct_string_view-8friend]

= Friend make_pct_string_view



== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L266[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
result<xref:boost-urls-pct_string_view[pct_string_view]>
make_pct_string_view(string_view s) noexcept;
----


[#boost-urls-pct_string_view-decoded_size]

= Function pct_string_view::decoded_size

pass:v,q[Return the decoded size]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L287[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
decoded_size() const noexcept;
----

== Description

pass:v,q[This function returns the number of] pass:v,q[characters in the resulting string if]
pass:v,q[percent escapes were converted into]
pass:v,q[ordinary characters.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-pct_string_view-operator_star]

= Function pct_string_view::operator*

pass:v,q[Return the string as a range of decoded characters]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L304[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view[decode_view]
operator*() const noexcept;
----

== Description


=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `decode_view` 





[#boost-urls-pct_string_view-decode]

= Function pct_string_view::decode

pass:v,q[Return the string with percent-decoding]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L345[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
decode(
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {},
    StringToken&& token) const;
----

== Description

pass:v,q[This function converts percent escapes] pass:v,q[in the string into ordinary characters]
pass:v,q[and returns the result.]
pass:v,q[When called with no arguments, the]
pass:v,q[return type is `std::string`.]
pass:v,q[Otherwise, the return type and style]
pass:v,q[of output is determined by which string]
pass:v,q[token is passed.]

=== Example
[,cpp]
----
assert( pct_string_view( "Program%20Files" ).decode() == "Program Files" );
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]
pass:v,q[String tokens may throw exceptions.]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *opt*
| `encoding_opts`

| *token*
| ``

|===




[#boost-urls-pct_string_view-operator_ptr]

= Function pct_string_view::operator->



== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L366[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const xref:boost-urls-pct_string_view[pct_string_view]*
operator->() const noexcept;
----


[#boost-urls-pct_string_view-swap]

= Function pct_string_view::swap

pass:v,q[Swap]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L378[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
swap(xref:boost-urls-pct_string_view[pct_string_view]& s) noexcept;
----


[#boost-urls-make_pct_string_view_unsafe]

= Function make_pct_string_view_unsafe



== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L34[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
make_pct_string_view_unsafe(
    const char* data,
    size_t size,
    size_t decoded_size) noexcept;
----


[#boost-urls-make_pct_string_view]

= Function make_pct_string_view

pass:v,q[Return a valid percent-encoded string]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L425[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-pct_string_view[pct_string_view]>
make_pct_string_view(string_view s) noexcept;
----

== Description

pass:v,q[If `s` is a valid percent-encoded string,] pass:v,q[the function returns the buffer as a valid]
pass:v,q[view which may be used to perform decoding]
pass:v,q[or measurements.]
pass:v,q[Otherwise the result contains an error code.]
pass:v,q[Upon success, the returned view references]
pass:v,q[the original character buffer;]
pass:v,q[Ownership is not transferred.]

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-encoded_size]

= Function encoded_size

pass:v,q[Return the buffer size needed for percent-encoding]


== Synopsis

Declared in header `</boost/url/encode.hpp#L62[boost/url/encode.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
size_t
encoded_size(
    string_view s,
    const CharSet& unreserved,
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {}) noexcept;
----

== Description

pass:v,q[This function returns the exact number] pass:v,q[of bytes necessary to store the result]
pass:v,q[of applying percent-encoding to the]
pass:v,q[string using the given options and]
pass:v,q[character set.]
pass:v,q[No encoding is actually performed.]

=== Example
[,cpp]
----
assert( encoded_size( "My Stuff", pchars ) == 10 );
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-2.1[2.1. Percent-Encoding (rfc3986)]



== Return Value

* `size_t` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

| *unreserved*
| ``

| *opt*
| `encoding_opts`

|===




[#boost-urls-encode]

= Overload set encode

== Members


pass:v,q[Apply percent-encoding to a string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
size_t
encode(
    char* dest,
    size_t size,
    string_view s,
    const CharSet& unreserved,
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {});
  xref:boost-urls-encode-09[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return a percent-encoded string]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string],
    class CharSet>
StringToken::result_type
encode(
    string_view s,
    const CharSet& unreserved,
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {},
    StringToken&& token) noexcept;
  xref:boost-urls-encode-04[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-encode_unsafe]

= Function encode_unsafe



== Synopsis

Declared in header `</boost/url/encode.hpp#L129[boost/url/encode.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
size_t
encode_unsafe(
    char* dest,
    size_t size,
    string_view s,
    const CharSet& unreserved,
    xref:boost-urls-encoding_opts[encoding_opts] opt);
----


[#boost-urls-operator_eq]

= Overload set operator==

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator==(
    const S0& s0,
    const S1& s1) noexcept;
  xref:boost-urls-operator_eq-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if two addresses are equal]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-ipv4_address[ipv4_address]& a1,
    const xref:boost-urls-ipv4_address[ipv4_address]& a2) noexcept;
  xref:boost-urls-operator_eq-0f2[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if two addresses are equal]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-ipv6_address[ipv6_address]& a1,
    const xref:boost-urls-ipv6_address[ipv6_address]& a2) noexcept;
  xref:boost-urls-operator_eq-0fd[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
  xref:boost-urls-operator_eq-09[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it0,
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it1) noexcept;
  xref:boost-urls-operator_eq-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two URLs]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
  xref:boost-urls-operator_eq-01[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-operator_not_eq]

= Overload set operator!=

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator!=(
    const S0& s0,
    const S1& s1) noexcept;
  xref:boost-urls-operator_not_eq-03b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if two addresses are not equal]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-ipv4_address[ipv4_address]& a1,
    const xref:boost-urls-ipv4_address[ipv4_address]& a2) noexcept;
  xref:boost-urls-operator_not_eq-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return true if two addresses are not equal]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-ipv6_address[ipv6_address]& a1,
    const xref:boost-urls-ipv6_address[ipv6_address]& a2) noexcept;
  xref:boost-urls-operator_not_eq-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
  xref:boost-urls-operator_not_eq-037[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it0,
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it1) noexcept;
  xref:boost-urls-operator_not_eq-0f[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two URLs]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
  xref:boost-urls-operator_not_eq-04[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-operator_lt]

= Overload set operator<

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<(
    const S0& s0,
    const S1& s1) noexcept;
  xref:boost-urls-operator_lt-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
  xref:boost-urls-operator_lt-0a[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two URLs]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
  xref:boost-urls-operator_lt-04[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-operator_le]

= Overload set operator<=

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<=(
    const S0& s0,
    const S1& s1) noexcept;
  xref:boost-urls-operator_le-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
  xref:boost-urls-operator_le-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two URLs]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
  xref:boost-urls-operator_le-0a[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-operator_gt]

= Overload set operator>

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>(
    const S0& s0,
    const S1& s1) noexcept;
  xref:boost-urls-operator_gt-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
  xref:boost-urls-operator_gt-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two URLs]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
  xref:boost-urls-operator_gt-09[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-operator_ge]

= Overload set operator>=

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>=(
    const S0& s0,
    const S1& s1) noexcept;
  xref:boost-urls-operator_ge-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
  xref:boost-urls-operator_ge-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the result of comparing two URLs]


[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
  xref:boost-urls-operator_ge-00[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-operator_lshift]

= Overload set operator<<

== Members


pass:v,q[Format the string with percent-decoding applied to the output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-decode_view[decode_view]& s);
  xref:boost-urls-operator_lshift-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format the address to an output stream.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-ipv4_address[ipv4_address]& addr);
  xref:boost-urls-operator_lshift-008[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format the address to an output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-ipv6_address[ipv6_address]& addr);
  xref:boost-urls-operator_lshift-001[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format the encoded authority to the output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-authority_view[authority_view]& a);
  xref:boost-urls-operator_lshift-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format to an output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-segments_encoded_base[segments_encoded_base]& ps);
  xref:boost-urls-operator_lshift-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format to an output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-segments_base[segments_base]& ps);
  xref:boost-urls-operator_lshift-0b9[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format to an output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-params_encoded_base[params_encoded_base]& qp);
  xref:boost-urls-operator_lshift-0b8[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format to an output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-params_base[params_base]& qp);
  xref:boost-urls-operator_lshift-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Format the url to the output stream]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-url_view_base[url_view_base]& u);
  xref:boost-urls-operator_lshift-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-no_value_t]

= Class no_value_t

pass:v,q[The type of no_value]


== Synopsis

Declared in header `</boost/url/param.hpp#L30[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct no_value_t;
----




[#boost-urls-param_pct_view]

= Class param_pct_view

pass:v,q[A query parameter]


== Synopsis

Declared in header `</boost/url/param.hpp#L638[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct param_pct_view;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-param_pct_view-2conversion-00[`pass:v[operator param]`] |
pass:v,q[Conversion]

|xref:boost-urls-param_pct_view-2conversion-0c[`pass:v[operator param_view]`] |

|xref:boost-urls-param_pct_view-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-param_pct_view-2constructor[`pass:v[param_pct_view]`] |
pass:v,q[Construction]

pass:v,q[Constructor]

|===
==  Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-param_pct_view-has_value[`pass:v[has_value]`] |
pass:v,q[True if a value is present]

|xref:boost-urls-param_pct_view-key[`pass:v[key]`] |
pass:v,q[The key]

|xref:boost-urls-param_pct_view-value[`pass:v[value]`] |
pass:v,q[The value]

|===

== Description

pass:v,q[Objects of this type represent a single key] pass:v,q[and value pair in a query string where a key]
pass:v,q[is always present and may be empty, while the]
pass:v,q[presence of a value is indicated by]
xref:boost-urls-param_pct_view-has_value[has_value]
pass:v,q[equal to true.]
pass:v,q[An empty value is distinct from no value.]
pass:v,q[The strings may have percent escapes, and]
pass:v,q[offer an additional invariant: they never]
pass:v,q[contain an invalid percent-encoding.]
pass:v,q[For most usages, key comparisons are]
pass:v,q[case-sensitive and duplicate keys in]
pass:v,q[a query are possible. However, it is]
pass:v,q[the authority that has final control]
pass:v,q[over how the query is interpreted.]
pass:v,q[Keys and values in this object reference]
pass:v,q[external character buffers.]
pass:v,q[Ownership of the buffers is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the assigned buffers remain valid until]
pass:v,q[they are no longer referenced.]

=== BNF
[,cpp]
----
query-params    = query-param *( "&" query-param )
query-param     = key [ "=" value ]
key             = *qpchar
value           = *( qpchar / "=" )
----

=== Specification

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]




[#boost-urls-param_pct_view-key]

= param_pct_view::key

pass:v,q[The key]


== Synopsis

Declared in header `</boost/url/param.hpp#L648[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view] key;
----

== Description

pass:v,q[For most usages, key comparisons are] pass:v,q[case-sensitive and duplicate keys in]
pass:v,q[a query are possible. However, it is]
pass:v,q[the authority that has final control]
pass:v,q[over how the query is interpreted.]



[#boost-urls-param_pct_view-value]

= param_pct_view::value

pass:v,q[The value]


== Synopsis

Declared in header `</boost/url/param.hpp#L656[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view] value;
----

== Description

pass:v,q[The presence of a value is indicated by] xref:boost-urls-param_pct_view-has_value[has_value]
pass:v,q[equal to true.]
pass:v,q[An empty value is distinct from no value.]



[#boost-urls-param_pct_view-has_value]

= param_pct_view::has_value

pass:v,q[True if a value is present]


== Synopsis

Declared in header `</boost/url/param.hpp#L664[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool has_value;
----

== Description

pass:v,q[The presence of a value is indicated by] pass:v,q[`has_value == true`.]
pass:v,q[An empty value is distinct from no value.]



[#boost-urls-param_pct_view-2constructor]

= Overload set param_pct_view::param_pct_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
param_pct_view() = default;
  xref:boost-urls-param_pct_view-2constructor-00[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
param_pct_view(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-pct_string_view[pct_string_view] value) noexcept;
  xref:boost-urls-param_pct_view-2constructor-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class OptionalString>
param_pct_view(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    const OptionalString& value);
  xref:boost-urls-param_pct_view-2constructor-05[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construction]


[source,cpp,subs="verbatim,macros,-callouts"]
----
param_pct_view(const xref:boost-urls-param_view[param_view]& p);
  xref:boost-urls-param_pct_view-2constructor-03[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
param_pct_view(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-pct_string_view[pct_string_view] value,
    bool has_value) noexcept;
  xref:boost-urls-param_pct_view-2constructor-02[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-param_pct_view-2conversion-00]

= Function param_pct_view::operator param

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/param.hpp#L840[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-param[param]() const;
----

== Description

pass:v,q[This function performs a conversion from] pass:v,q[a reference-like query parameter to one]
pass:v,q[retaining ownership of the strings by]
pass:v,q[making a copy.]

=== Complexity
pass:v,q[Linear in `this->key.size() + this->value.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `param` 





[#boost-urls-param_pct_view-2conversion-0c]

= Function param_pct_view::operator param_view



== Synopsis

Declared in header `</boost/url/param.hpp#L850[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-param_view[param_view]() const noexcept;
----


[#boost-urls-param_pct_view-operator_ptr]

= Function param_pct_view::operator->



== Synopsis

Declared in header `</boost/url/param.hpp#L859[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const xref:boost-urls-param_pct_view[param_pct_view]*
operator->() const noexcept;
----


[#boost-urls-param_view]

= Class param_view

pass:v,q[A query parameter]


== Synopsis

Declared in header `</boost/url/param.hpp#L404[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct param_view;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-param_view-2conversion[`pass:v[operator param]`] |
pass:v,q[Conversion]

|xref:boost-urls-param_view-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-param_view-2constructor[`pass:v[param_view]`] |
pass:v,q[Constructor]

|===
==  Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-param_view-has_value[`pass:v[has_value]`] |
pass:v,q[True if a value is present]

|xref:boost-urls-param_view-key[`pass:v[key]`] |
pass:v,q[The key]

|xref:boost-urls-param_view-value[`pass:v[value]`] |
pass:v,q[The value]

|===

== Description

pass:v,q[Objects of this type represent a single key] pass:v,q[and value pair in a query string where a key]
pass:v,q[is always present and may be empty, while the]
pass:v,q[presence of a value is indicated by]
xref:boost-urls-param_view-has_value[has_value]
pass:v,q[equal to true.]
pass:v,q[An empty value is distinct from no value.]
pass:v,q[Depending on where the object was obtained,]
pass:v,q[the strings may or may not contain percent]
pass:v,q[escapes.]
pass:v,q[For most usages, key comparisons are]
pass:v,q[case-sensitive and duplicate keys in]
pass:v,q[a query are possible. However, it is]
pass:v,q[the authority that has final control]
pass:v,q[over how the query is interpreted.]
pass:v,q[Keys and values in this object reference]
pass:v,q[external character buffers.]
pass:v,q[Ownership of the buffers is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the assigned buffers remain valid until]
pass:v,q[they are no longer referenced.]

=== BNF
[,cpp]
----
query-params    = query-param *( "&" query-param )
query-param     = key [ "=" value ]
key             = *qpchar
value           = *( qpchar / "=" )
----

=== Specification

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]




[#boost-urls-param_view-key]

= param_view::key

pass:v,q[The key]


== Synopsis

Declared in header `</boost/url/param.hpp#L414[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view key;
----

== Description

pass:v,q[For most usages, key comparisons are] pass:v,q[case-sensitive and duplicate keys in]
pass:v,q[a query are possible. However, it is]
pass:v,q[the authority that has final control]
pass:v,q[over how the query is interpreted.]



[#boost-urls-param_view-value]

= param_view::value

pass:v,q[The value]


== Synopsis

Declared in header `</boost/url/param.hpp#L422[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view value;
----

== Description

pass:v,q[The presence of a value is indicated by] xref:boost-urls-param_view-has_value[has_value]
pass:v,q[equal to true.]
pass:v,q[An empty value is distinct from no value.]



[#boost-urls-param_view-has_value]

= param_view::has_value

pass:v,q[True if a value is present]


== Synopsis

Declared in header `</boost/url/param.hpp#L430[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool has_value;
----

== Description

pass:v,q[The presence of a value is indicated by] pass:v,q[`has_value == true`.]
pass:v,q[An empty value is distinct from no value.]



[#boost-urls-param_view-2constructor]

= Overload set param_view::param_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
param_view() = default;
  xref:boost-urls-param_view-2constructor-07a[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class OptionalString>
param_view(
    string_view key,
    const OptionalString& value) noexcept;
  xref:boost-urls-param_view-2constructor-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
param_view(const xref:boost-urls-param[param]& other) noexcept;
  xref:boost-urls-param_view-2constructor-07e[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
param_view(
    string_view key_,
    string_view value_,
    bool has_value_) noexcept;
  xref:boost-urls-param_view-2constructor-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-param_view-2conversion]

= Function param_view::operator param

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/param.hpp#L554[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-param[param]();
----

== Description

pass:v,q[This function performs a conversion from] pass:v,q[a reference-like query parameter to one]
pass:v,q[retaining ownership of the strings by]
pass:v,q[making a copy.]
pass:v,q[No validation is performed on the strings.]

=== Complexity
pass:v,q[Linear in `this->key.size() + this->value.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `param` 





[#boost-urls-param_view-operator_ptr]

= Function param_view::operator->



== Synopsis

Declared in header `</boost/url/param.hpp#L563[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const xref:boost-urls-param_view[param_view]*
operator->() const noexcept;
----


[#boost-urls-no_value]

= no_value

pass:v,q[Constant indicating no value in a param]


== Synopsis

Declared in header `</boost/url/param.hpp#L36[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-no_value_t[no_value_t] no_value;
----


[#boost-urls-param]

= Class param

pass:v,q[A query parameter]


== Synopsis

Declared in header `</boost/url/param.hpp#L75[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct param;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-param-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-param-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-param-2constructor[`pass:v[param]`] |
pass:v,q[Constructor]

|===
==  Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-param-has_value[`pass:v[has_value]`] |
pass:v,q[True if a value is present]

|xref:boost-urls-param-key[`pass:v[key]`] |
pass:v,q[The key]

|xref:boost-urls-param-value[`pass:v[value]`] |
pass:v,q[The value]

|===

== Description

pass:v,q[Objects of this type represent a single key] pass:v,q[and value pair in a query string where a key]
pass:v,q[is always present and may be empty, while the]
pass:v,q[presence of a value is indicated by]
xref:boost-urls-param-has_value[has_value]
pass:v,q[equal to true.]
pass:v,q[An empty value is distinct from no value.]
pass:v,q[Depending on where the object was obtained,]
pass:v,q[the strings may or may not contain percent]
pass:v,q[escapes.]
pass:v,q[For most usages, key comparisons are]
pass:v,q[case-sensitive and duplicate keys in]
pass:v,q[a query are possible. However, it is]
pass:v,q[the authority that has final control]
pass:v,q[over how the query is interpreted.]

=== BNF
[,cpp]
----
query-params    = query-param *( "&" query-param )
query-param     = key [ "=" value ]
key             = *qpchar
value           = *( qpchar / "=" )
----

=== Specification

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]




[#boost-urls-param-key]

= param::key

pass:v,q[The key]


== Synopsis

Declared in header `</boost/url/param.hpp#L85[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string key;
----

== Description

pass:v,q[For most usages, key comparisons are] pass:v,q[case-sensitive and duplicate keys in]
pass:v,q[a query are possible. However, it is]
pass:v,q[the authority that has final control]
pass:v,q[over how the query is interpreted.]



[#boost-urls-param-value]

= param::value

pass:v,q[The value]


== Synopsis

Declared in header `</boost/url/param.hpp#L93[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string value;
----

== Description

pass:v,q[The presence of a value is indicated by] xref:boost-urls-param-has_value[has_value]
pass:v,q[equal to true.]
pass:v,q[An empty value is distinct from no value.]



[#boost-urls-param-has_value]

= param::has_value

pass:v,q[True if a value is present]


== Synopsis

Declared in header `</boost/url/param.hpp#L101[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool has_value;
----

== Description

pass:v,q[The presence of a value is indicated by] pass:v,q[`has_value == true`.]
pass:v,q[An empty value is distinct from no value.]



[#boost-urls-param-2constructor]

= Overload set param::param

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
param() = default;
  xref:boost-urls-param-2constructor-09[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
param(xref:boost-urls-param[param]&& other) noexcept;
  xref:boost-urls-param-2constructor-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
param(const xref:boost-urls-param[param]& other) = default;
  xref:boost-urls-param-2constructor-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class OptionalString>
param(
    string_view key,
    const OptionalString& value);
  xref:boost-urls-param-2constructor-0b[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
param(
    string_view key,
    string_view value,
    bool has_value) noexcept;
  xref:boost-urls-param-2constructor-0a[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-param-operator_assign]

= Overload set param::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(xref:boost-urls-param[param]&& other) noexcept;
  xref:boost-urls-param-operator_assign-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(const xref:boost-urls-param[param]&) = default;
  xref:boost-urls-param-operator_assign-0cd[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(const xref:boost-urls-param_view[param_view]& other);
  xref:boost-urls-param-operator_assign-0cb[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(const xref:boost-urls-param_pct_view[param_pct_view]& other);
  xref:boost-urls-param-operator_assign-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-param-operator_ptr]

= Function param::operator->



== Synopsis

Declared in header `</boost/url/param.hpp#L329[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const xref:boost-urls-param[param]*
operator->() const noexcept;
----


[#boost-urls-host_type]

= Enum host_type

pass:v,q[Identifies the type of host in a URL.]


== Synopsis

Declared in header `</boost/url/host_type.hpp#L24[boost/url/host_type.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
enum host_type : int;
----

== Members
[,cols=2]
|===
|Name |Description
|none |pass:v,q[No host is specified.]

|name |pass:v,q[A host is specified by reg-name.]

|ipv4 |pass:v,q[A host is specified by] xref:boost-urls-ipv4_address[ipv4_address.]

|ipv6 |pass:v,q[A host is specified by] xref:boost-urls-ipv6_address[ipv6_address.]

|ipvfuture |pass:v,q[A host is specified by IPvFuture.]

|===

== Description

pass:v,q[Values of this type are returned by URL views] pass:v,q[and containers to indicate the type of host]
pass:v,q[present in a URL.]


[#boost-urls-host_type-none]

= Enumerator host_type::none

pass:v,q[No host is specified.]


== Synopsis

Declared in header `</boost/url/host_type.hpp#L32[boost/url/host_type.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
none
----


[#boost-urls-host_type-name]

= Enumerator host_type::name

pass:v,q[A host is specified by reg-name.]


== Synopsis

Declared in header `</boost/url/host_type.hpp#L37[boost/url/host_type.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
name
----


[#boost-urls-host_type-ipv4]

= Enumerator host_type::ipv4

pass:v,q[A host is specified by] xref:boost-urls-ipv4_address[ipv4_address.]


== Synopsis

Declared in header `</boost/url/host_type.hpp#L42[boost/url/host_type.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv4
----


[#boost-urls-host_type-ipv6]

= Enumerator host_type::ipv6

pass:v,q[A host is specified by] xref:boost-urls-ipv6_address[ipv6_address.]


== Synopsis

Declared in header `</boost/url/host_type.hpp#L47[boost/url/host_type.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv6
----


[#boost-urls-host_type-ipvfuture]

= Enumerator host_type::ipvfuture

pass:v,q[A host is specified by IPvFuture.]


== Synopsis

Declared in header `</boost/url/host_type.hpp#L52[boost/url/host_type.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipvfuture
----


[#boost-urls-error]

= Enum error

pass:v,q[Error codes returned the library]


== Synopsis

Declared in header `</boost/url/error.hpp#L22[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
enum error : int;
----

== Members
[,cols=2]
|===
|Name |Description
|success |pass:v,q[The operation completed successfully.]

|illegal_null |pass:v,q[Null encountered in pct-encoded.]

|illegal_reserved_char |pass:v,q[Illegal reserved character in encoded string.]

|non_canonical |pass:v,q[A grammar element was not in canonical form.]

|bad_pct_hexdig |pass:v,q[Bad hexadecimal digit.]

|incomplete_encoding |pass:v,q[The percent-encoded sequence is incomplete.]

|missing_pct_hexdig |pass:v,q[Missing hexadecimal digit.]

|no_space |pass:v,q[No space in output buffer]

|not_a_base |pass:v,q[The URL is not a base URL]

|===


[#boost-urls-error-success]

= Enumerator error::success

pass:v,q[The operation completed successfully.]


== Synopsis

Declared in header `</boost/url/error.hpp#L30[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
success = 0
----


[#boost-urls-error-illegal_null]

= Enumerator error::illegal_null

pass:v,q[Null encountered in pct-encoded.]


== Synopsis

Declared in header `</boost/url/error.hpp#L35[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
illegal_null
----


[#boost-urls-error-illegal_reserved_char]

= Enumerator error::illegal_reserved_char

pass:v,q[Illegal reserved character in encoded string.]


== Synopsis

Declared in header `</boost/url/error.hpp#L40[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
illegal_reserved_char
----


[#boost-urls-error-non_canonical]

= Enumerator error::non_canonical

pass:v,q[A grammar element was not in canonical form.]


== Synopsis

Declared in header `</boost/url/error.hpp#L45[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
non_canonical
----


[#boost-urls-error-bad_pct_hexdig]

= Enumerator error::bad_pct_hexdig

pass:v,q[Bad hexadecimal digit.]


== Synopsis

Declared in header `</boost/url/error.hpp#L54[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bad_pct_hexdig
----

== Description

pass:v,q[This error condition is fatal.]



[#boost-urls-error-incomplete_encoding]

= Enumerator error::incomplete_encoding

pass:v,q[The percent-encoded sequence is incomplete.]


== Synopsis

Declared in header `</boost/url/error.hpp#L61[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
incomplete_encoding
----

== Description

pass:v,q[This error condition is fatal.]



[#boost-urls-error-missing_pct_hexdig]

= Enumerator error::missing_pct_hexdig

pass:v,q[Missing hexadecimal digit.]


== Synopsis

Declared in header `</boost/url/error.hpp#L68[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
missing_pct_hexdig
----

== Description

pass:v,q[This error condition is fatal.]



[#boost-urls-error-no_space]

= Enumerator error::no_space

pass:v,q[No space in output buffer]


== Synopsis

Declared in header `</boost/url/error.hpp#L77[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
no_space
----

== Description

pass:v,q[This error is returned when a provided] pass:v,q[output buffer was too small to hold]
pass:v,q[the complete result of an algorithm.]



[#boost-urls-error-not_a_base]

= Enumerator error::not_a_base

pass:v,q[The URL is not a base URL]


== Synopsis

Declared in header `</boost/url/error.hpp#L82[boost/url/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
not_a_base
----


[#boost-urls-make_error_code]

= Function make_error_code



== Synopsis

Declared in header `</boost/url/impl/error.hpp#L64[boost/url/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
error_code
make_error_code(xref:boost-urls-error[error] ev) noexcept;
----


[#boost-urls-ipv4_address]

= Class ipv4_address

pass:v,q[An IP version 4 style address.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L53[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class ipv4_address;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv4_address-bytes_type[`pass:v[bytes_type]`] |
pass:v,q[The type used to represent an address as an array of bytes]

|xref:boost-urls-ipv4_address-uint_type[`pass:v[uint_type]`] |
pass:v,q[The type used to represent an address as an unsigned integer]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv4_address-2constructor[`pass:v[ipv4_address]`] |
pass:v,q[Construct from a string.]

pass:v,q[Construct from an array of bytes.]

pass:v,q[Construct from an unsigned integer.]

pass:v,q[Constructor.]

|xref:boost-urls-ipv4_address-is_loopback[`pass:v[is_loopback]`] |
pass:v,q[Return true if the address is a loopback address]

|xref:boost-urls-ipv4_address-is_multicast[`pass:v[is_multicast]`] |
pass:v,q[Return true if the address is a multicast address]

|xref:boost-urls-ipv4_address-is_unspecified[`pass:v[is_unspecified]`] |
pass:v,q[Return true if the address is unspecified]

|xref:boost-urls-ipv4_address-operator_assign[`pass:v[operator=]`] |
pass:v,q[Copy Assignment.]

|xref:boost-urls-ipv4_address-to_buffer[`pass:v[to_buffer]`] |
pass:v,q[Write a dotted decimal string representing the address to a buffer]

|xref:boost-urls-ipv4_address-to_bytes[`pass:v[to_bytes]`] |
pass:v,q[Return the address as bytes, in network byte order.]

|xref:boost-urls-ipv4_address-to_string[`pass:v[to_string]`] |
pass:v,q[Return the address as a string in dotted decimal format]

|xref:boost-urls-ipv4_address-to_uint[`pass:v[to_uint]`] |
pass:v,q[Return the address as an unsigned integer.]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv4_address-any[`pass:v[any]`] |
pass:v,q[Return an address object that represents any address]

|xref:boost-urls-ipv4_address-broadcast[`pass:v[broadcast]`] |
pass:v,q[Return an address object that represents the broadcast address]

|xref:boost-urls-ipv4_address-loopback[`pass:v[loopback]`] |
pass:v,q[Return an address object that represents the loopback address]

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv4_address-max_str_len[`pass:v[max_str_len]`] |
pass:v,q[The number of characters in the longest possible IPv4 string.]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv4_address-8friend-08[`pass:v[operator!=]`] |
pass:v,q[Return true if two addresses are not equal]

|xref:boost-urls-ipv4_address-8friend-05[`pass:v[operator<<]`] |

|xref:boost-urls-ipv4_address-8friend-01[`pass:v[operator==]`] |
pass:v,q[Return true if two addresses are equal]

|===

== Description

pass:v,q[Objects of this type are used to construct,] pass:v,q[parse, and manipulate IP version 6 addresses.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]




[#boost-urls-ipv4_address-max_str_len]

= ipv4_address::max_str_len

pass:v,q[The number of characters in the longest possible IPv4 string.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L60[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
const size_t max_str_len;
----

== Description

pass:v,q[The longest ipv4 address string is "255.255.255.255".]



[#boost-urls-ipv4_address-uint_type]

= ipv4_address::uint_type

pass:v,q[The type used to represent an address as an unsigned integer]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L66[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using uint_type = uint_least32_t;
----


[#boost-urls-ipv4_address-bytes_type]

= ipv4_address::bytes_type

pass:v,q[The type used to represent an address as an array of bytes]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L71[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using bytes_type = array<unsigned char, 4>;
----


[#boost-urls-ipv4_address-2constructor]

= Overload set ipv4_address::ipv4_address

== Members


pass:v,q[Constructor.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv4_address() = default;
  xref:boost-urls-ipv4_address-2constructor-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv4_address(const xref:boost-urls-ipv4_address[ipv4_address]&) = default;
  xref:boost-urls-ipv4_address-2constructor-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construct from an unsigned integer.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv4_address(xref:boost-urls-ipv4_address-uint_type[uint_type] u) noexcept;
  xref:boost-urls-ipv4_address-2constructor-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construct from an array of bytes.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv4_address(const xref:boost-urls-ipv4_address-bytes_type[bytes_type]& bytes) noexcept;
  xref:boost-urls-ipv4_address-2constructor-0f[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construct from a string.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv4_address(string_view s);
  xref:boost-urls-ipv4_address-2constructor-08[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-ipv4_address-operator_assign]

= Function ipv4_address::operator=

pass:v,q[Copy Assignment.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L85[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-ipv4_address[ipv4_address]&
operator=(const xref:boost-urls-ipv4_address[ipv4_address]&) = default;
----


[#boost-urls-ipv4_address-to_bytes]

= Function ipv4_address::to_bytes

pass:v,q[Return the address as bytes, in network byte order.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L153[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-ipv4_address-bytes_type[bytes_type]
to_bytes() const noexcept;
----


[#boost-urls-ipv4_address-to_uint]

= Function ipv4_address::to_uint

pass:v,q[Return the address as an unsigned integer.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L159[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-ipv4_address-uint_type[uint_type]
to_uint() const noexcept;
----


[#boost-urls-ipv4_address-to_string]

= Function ipv4_address::to_string

pass:v,q[Return the address as a string in dotted decimal format]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L196[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
to_string(StringToken&& token) const;
----

== Description

pass:v,q[When called with no arguments, the] pass:v,q[return type is `std::string`.]
pass:v,q[Otherwise, the return type and style]
pass:v,q[of output is determined by which string]
pass:v,q[token is passed.]

=== Example
[,cpp]
----
assert( ipv4_address(0x01020304).to_string() == "1.2.3.4" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[String tokens may throw exceptions.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.2[            2.2. Text Representation of Addresses (rfc4291)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-ipv4_address-to_buffer]

= Function ipv4_address::to_buffer

pass:v,q[Write a dotted decimal string representing the address to a buffer]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L218[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
to_buffer(
    char* dest,
    size_t dest_size) const;
----

== Description

pass:v,q[The resulting buffer is not null-terminated.]



== Return Value

* `string_view` 


== Parameters

|===
| Name | Type 

| *dest*
| ``

| *dest_size*
| `size_t`

|===




[#boost-urls-ipv4_address-is_loopback]

= Function ipv4_address::is_loopback

pass:v,q[Return true if the address is a loopback address]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L226[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_loopback() const noexcept;
----


[#boost-urls-ipv4_address-is_unspecified]

= Function ipv4_address::is_unspecified

pass:v,q[Return true if the address is unspecified]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L232[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_unspecified() const noexcept;
----


[#boost-urls-ipv4_address-is_multicast]

= Function ipv4_address::is_multicast

pass:v,q[Return true if the address is a multicast address]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L238[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_multicast() const noexcept;
----


[#boost-urls-ipv4_address-8friend-01]

= Friend operator==

pass:v,q[Return true if two addresses are equal]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L243[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator==(
    const xref:boost-urls-ipv4_address[ipv4_address]& a1,
    const xref:boost-urls-ipv4_address[ipv4_address]& a2) noexcept;
----


[#boost-urls-ipv4_address-8friend-08]

= Friend operator!=

pass:v,q[Return true if two addresses are not equal]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L254[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator!=(
    const xref:boost-urls-ipv4_address[ipv4_address]& a1,
    const xref:boost-urls-ipv4_address[ipv4_address]& a2) noexcept;
----


[#boost-urls-ipv4_address-any]

= Function ipv4_address::any

pass:v,q[Return an address object that represents any address]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L265[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static
xref:boost-urls-ipv4_address[ipv4_address]
any() noexcept;
----


[#boost-urls-ipv4_address-loopback]

= Function ipv4_address::loopback

pass:v,q[Return an address object that represents the loopback address]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L274[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static
xref:boost-urls-ipv4_address[ipv4_address]
loopback() noexcept;
----


[#boost-urls-ipv4_address-broadcast]

= Function ipv4_address::broadcast

pass:v,q[Return an address object that represents the broadcast address]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L283[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static
xref:boost-urls-ipv4_address[ipv4_address]
broadcast() noexcept;
----


[#boost-urls-ipv4_address-8friend-05]

= Friend operator<<



== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L291[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-ipv4_address[ipv4_address]& addr);
----


[#boost-urls-parse_ipv4_address]

= Function parse_ipv4_address

pass:v,q[Return an IPv4 address from an IP address string in dotted decimal form]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L337[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-ipv4_address[ipv4_address]>
parse_ipv4_address(string_view s) noexcept;
----


[#boost-urls-ipv6_address]

= Class ipv6_address

pass:v,q[An IP version 6 style address.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L64[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class ipv6_address;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv6_address-bytes_type[`pass:v[bytes_type]`] |
pass:v,q[The type used to represent an address as an array of bytes.]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv6_address-2constructor[`pass:v[ipv6_address]`] |
pass:v,q[Construct from a string.]

pass:v,q[Construct from an IPv4 address.]

pass:v,q[Construct from an array of bytes.]

pass:v,q[Constructor.]

|xref:boost-urls-ipv6_address-is_loopback[`pass:v[is_loopback]`] |
pass:v,q[Return true if the address is a loopback address]

|xref:boost-urls-ipv6_address-is_unspecified[`pass:v[is_unspecified]`] |
pass:v,q[Return true if the address is unspecified]

|xref:boost-urls-ipv6_address-is_v4_mapped[`pass:v[is_v4_mapped]`] |
pass:v,q[Return true if the address is a mapped IPv4 address]

|xref:boost-urls-ipv6_address-operator_assign[`pass:v[operator=]`] |
pass:v,q[Copy Assignment]

|xref:boost-urls-ipv6_address-to_buffer[`pass:v[to_buffer]`] |
pass:v,q[Write a dotted decimal string representing the address to a buffer]

|xref:boost-urls-ipv6_address-to_bytes[`pass:v[to_bytes]`] |
pass:v,q[Return the address as bytes, in network byte order]

|xref:boost-urls-ipv6_address-to_string[`pass:v[to_string]`] |
pass:v,q[Return the address as a string.]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv6_address-loopback[`pass:v[loopback]`] |
pass:v,q[Return an address object that represents the loopback address]

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv6_address-max_str_len[`pass:v[max_str_len]`] |
pass:v,q[The number of characters in the longest possible IPv6 string.]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv6_address-8friend-01[`pass:v[operator!=]`] |
pass:v,q[Return true if two addresses are not equal]

|xref:boost-urls-ipv6_address-8friend-0b[`pass:v[operator<<]`] |

|xref:boost-urls-ipv6_address-8friend-0d[`pass:v[operator==]`] |
pass:v,q[Return true if two addresses are equal]

|===

== Description

pass:v,q[Objects of this type are used to construct,] pass:v,q[parse, and manipulate IP version 6 addresses.]

=== BNF
[,cpp]
----
IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]




[#boost-urls-ipv6_address-max_str_len]

= ipv6_address::max_str_len

pass:v,q[The number of characters in the longest possible IPv6 string.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L81[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
const size_t max_str_len;
----

== Description

pass:v,q[The longest IPv6 address is:]
[,cpp]
----
ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff
----



[#boost-urls-ipv6_address-bytes_type]

= ipv6_address::bytes_type

pass:v,q[The type used to represent an address as an array of bytes.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L89[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using bytes_type = array<unsigned char, 16>;
----

== Description

pass:v,q[Octets are stored in network byte order.]



[#boost-urls-ipv6_address-2constructor]

= Overload set ipv6_address::ipv6_address

== Members


pass:v,q[Constructor.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv6_address() = default;
  xref:boost-urls-ipv6_address-2constructor-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv6_address(const xref:boost-urls-ipv6_address[ipv6_address]&) = default;
  xref:boost-urls-ipv6_address-2constructor-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construct from an array of bytes.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv6_address(const xref:boost-urls-ipv6_address-bytes_type[bytes_type]& bytes) noexcept;
  xref:boost-urls-ipv6_address-2constructor-0a[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construct from an IPv4 address.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv6_address(const xref:boost-urls-ipv4_address[ipv4_address]& addr) noexcept;
  xref:boost-urls-ipv6_address-2constructor-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construct from a string.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv6_address(string_view s);
  xref:boost-urls-ipv6_address-2constructor-00[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-ipv6_address-operator_assign]

= Function ipv6_address::operator=

pass:v,q[Copy Assignment]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L112[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-ipv6_address[ipv6_address]&
operator=(const xref:boost-urls-ipv6_address[ipv6_address]&) = default;
----


[#boost-urls-ipv6_address-to_bytes]

= Function ipv6_address::to_bytes

pass:v,q[Return the address as bytes, in network byte order]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L175[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-ipv6_address-bytes_type[bytes_type]
to_bytes() const noexcept;
----


[#boost-urls-ipv6_address-to_string]

= Function ipv6_address::to_string

pass:v,q[Return the address as a string.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L223[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
to_string(StringToken&& token) const;
----

== Description

pass:v,q[The returned string does not] pass:v,q[contain surrounding square brackets.]
pass:v,q[When called with no arguments, the]
pass:v,q[return type is `std::string`.]
pass:v,q[Otherwise, the return type and style]
pass:v,q[of output is determined by which string]
pass:v,q[token is passed.]

=== Example
[,cpp]
----
ipv6_address::bytes_type b = {{
        0, 1, 0, 2, 0, 3, 0, 4,
        0, 5, 0, 6, 0, 7, 0, 8 }};
ipv6_address a(b);
assert(a.to_string() == "1:2:3:4:5:6:7:8");
assert( ipv4_address(0x01020304).to_string() == "1.2.3.4" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[String tokens may throw exceptions.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.2[            2.2. Text Representation of Addresses (rfc4291)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-ipv6_address-to_buffer]

= Function ipv6_address::to_buffer

pass:v,q[Write a dotted decimal string representing the address to a buffer]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L245[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
to_buffer(
    char* dest,
    size_t dest_size) const;
----

== Description

pass:v,q[The resulting buffer is not null-terminated.]



== Return Value

* `string_view` 


== Parameters

|===
| Name | Type 

| *dest*
| ``

| *dest_size*
| `size_t`

|===




[#boost-urls-ipv6_address-is_unspecified]

= Function ipv6_address::is_unspecified

pass:v,q[Return true if the address is unspecified]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L261[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_unspecified() const noexcept;
----

== Description

pass:v,q[The address 0:0:0:0:0:0:0:0 is called the] pass:v,q[unspecified address. It indicates the]
pass:v,q[absence of an address.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.5.2[            2.5.2. The Unspecified Address (rfc4291)]



== Return Value

* `bool` 





[#boost-urls-ipv6_address-is_loopback]

= Function ipv6_address::is_loopback

pass:v,q[Return true if the address is a loopback address]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L275[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_loopback() const noexcept;
----

== Description

pass:v,q[The unicast address 0:0:0:0:0:0:0:1 is called] pass:v,q[the loopback address. It may be used by a node]
pass:v,q[to send an IPv6 packet to itself.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.5.3[            2.5.3. The Loopback Address (rfc4291)]



== Return Value

* `bool` 





[#boost-urls-ipv6_address-is_v4_mapped]

= Function ipv6_address::is_v4_mapped

pass:v,q[Return true if the address is a mapped IPv4 address]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L288[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_v4_mapped() const noexcept;
----

== Description

pass:v,q[This address type is used to represent the] pass:v,q[addresses of IPv4 nodes as IPv6 addresses.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.5.5.2[            2.5.5.2. IPv4-Mapped IPv6 Address (rfc4291)]



== Return Value

* `bool` 





[#boost-urls-ipv6_address-8friend-0d]

= Friend operator==

pass:v,q[Return true if two addresses are equal]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L293[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator==(
    const xref:boost-urls-ipv6_address[ipv6_address]& a1,
    const xref:boost-urls-ipv6_address[ipv6_address]& a2) noexcept;
----


[#boost-urls-ipv6_address-8friend-01]

= Friend operator!=

pass:v,q[Return true if two addresses are not equal]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L304[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator!=(
    const xref:boost-urls-ipv6_address[ipv6_address]& a1,
    const xref:boost-urls-ipv6_address[ipv6_address]& a2) noexcept;
----


[#boost-urls-ipv6_address-loopback]

= Function ipv6_address::loopback

pass:v,q[Return an address object that represents the loopback address]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L324[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static
xref:boost-urls-ipv6_address[ipv6_address]
loopback() noexcept;
----

== Description

pass:v,q[The unicast address 0:0:0:0:0:0:0:1 is called] pass:v,q[the loopback address. It may be used by a node]
pass:v,q[to send an IPv6 packet to itself.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.5.3[            2.5.3. The Loopback Address (rfc4291)]



== Return Value

* `ipv6_address` 





[#boost-urls-ipv6_address-8friend-0b]

= Friend operator<<



== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L329[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-ipv6_address[ipv6_address]& addr);
----


[#boost-urls-parse_ipv6_address]

= Function parse_ipv6_address

pass:v,q[Parse a string containing an IPv6 address.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L391[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-ipv6_address[ipv6_address]>
parse_ipv6_address(string_view s) noexcept;
----

== Description

pass:v,q[This function attempts to parse the string] pass:v,q[as an IPv6 address and returns a result]
pass:v,q[containing the address upon success, or]
pass:v,q[an error code if the string does not contain]
pass:v,q[a valid IPv6 address.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-scheme]

= Enum scheme

pass:v,q[Identifies a known URL scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L33[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
enum scheme : unsigned short;
----

== Members
[,cols=2]
|===
|Name |Description
|none |pass:v,q[Indicates that no scheme is present]

|unknown |pass:v,q[Indicates the scheme is not a well-known scheme]

|ftp |pass:v,q[File Transfer Protocol (FTP)]

|file |pass:v,q[File URI Scheme]

|http |pass:v,q[The Hypertext Transfer Protocol URI Scheme]

|https |pass:v,q[The Secure Hypertext Transfer Protocol URI Scheme]

|ws |pass:v,q[The WebSocket URI Scheme]

|wss |pass:v,q[The Secure WebSocket URI Scheme]

|===

== Description


=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[3.1. Scheme (rfc3986)]


[#boost-urls-scheme-none]

= Enumerator scheme::none

pass:v,q[Indicates that no scheme is present]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L37[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
none = 0
----


[#boost-urls-scheme-unknown]

= Enumerator scheme::unknown

pass:v,q[Indicates the scheme is not a well-known scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L41[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
unknown
----


[#boost-urls-scheme-ftp]

= Enumerator scheme::ftp

pass:v,q[File Transfer Protocol (FTP)]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L55[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ftp
----

== Description

pass:v,q[FTP is a standard communication protocol] pass:v,q[used for the transfer of computer files]
pass:v,q[from a server to a client on a computer]
pass:v,q[network.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/draft-yevstifeyev-ftp-uri-scheme[           The 'ftp' URI Scheme]



[#boost-urls-scheme-file]

= Enumerator scheme::file

pass:v,q[File URI Scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L68[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
file
----

== Description

pass:v,q[The File URI Scheme is typically used] pass:v,q[to retrieve files from within one's]
pass:v,q[own computer.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc8089[           The "file" URI Scheme (rfc8089)]



[#boost-urls-scheme-http]

= Enumerator scheme::http

pass:v,q[The Hypertext Transfer Protocol URI Scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L80[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
http
----

== Description

pass:v,q[URLs of this type indicate a resource which] pass:v,q[is interacted with using the HTTP protocol.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc7230[            Hypertext Transfer Protocol (HTTP/1.1) (rfc7230)]



[#boost-urls-scheme-https]

= Enumerator scheme::https

pass:v,q[The Secure Hypertext Transfer Protocol URI Scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L93[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
https
----

== Description

pass:v,q[URLs of this type indicate a resource which] pass:v,q[is interacted with using the Secure HTTP]
pass:v,q[protocol.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc7230[            Hypertext Transfer Protocol (HTTP/1.1) (rfc7230)]



[#boost-urls-scheme-ws]

= Enumerator scheme::ws

pass:v,q[The WebSocket URI Scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L105[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ws
----

== Description

pass:v,q[URLs of this type indicate a resource which] pass:v,q[is interacted with using the WebSocket protocol.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc6455[            The WebSocket Protocol (rfc6455)]



[#boost-urls-scheme-wss]

= Enumerator scheme::wss

pass:v,q[The Secure WebSocket URI Scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L118[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
wss
----

== Description

pass:v,q[URLs of this type indicate a resource which] pass:v,q[is interacted with using the Secure WebSocket]
pass:v,q[protocol.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc6455[            The WebSocket Protocol (rfc6455)]



[#boost-urls-string_to_scheme]

= Function string_to_scheme

pass:v,q[Return the known scheme for a non-normalized string, if known]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L141[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-scheme[scheme]
string_to_scheme(string_view s) noexcept;
----

== Description

pass:v,q[If the string does not identify a known] pass:v,q[scheme, the value] xref:boost-urls-scheme-unknown[scheme::unknown]
pass:v,q[is]
pass:v,q[returned.]

=== BNF
[,cpp]
----
scheme      = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[3.1. Scheme (rfc3986)]



== Return Value

* `scheme` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-to_string]

= Function to_string

pass:v,q[Return the normalized string for a known scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L151[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
to_string(xref:boost-urls-scheme[scheme] s) noexcept;
----


[#boost-urls-default_port]

= Function default_port

pass:v,q[Return the default port for a known scheme]


== Synopsis

Declared in header `</boost/url/scheme.hpp#L174[boost/url/scheme.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
uint16_t
default_port(xref:boost-urls-scheme[scheme] s) noexcept;
----

== Description

pass:v,q[This function returns the default port] pass:v,q[for the known schemes. If the value does]
pass:v,q[not represent a known scheme or the scheme]
pass:v,q[does not represent a protocol, the function]
pass:v,q[returns zero.]
pass:v,q[The following ports are returned by the]
pass:v,q[function:]

* xref:boost-urls-scheme-ftp[scheme::ftp]
pass:v,q[= 21]

* xref:boost-urls-scheme-http[scheme::http,]
xref:boost-urls-scheme-ws[scheme::ws]
pass:v,q[= 80]

* xref:boost-urls-scheme-https[scheme::https,]
xref:boost-urls-scheme-wss[scheme::wss]
pass:v,q[= 443]



== Return Value

* `uint16_t` 


== Parameters

|===
| Name | Type 

| *s*
| `scheme`

|===




[#boost-urls-url_view]

= Class url_view

pass:v,q[A non-owning reference to a valid URL]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L74[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class url_view
    : public xref:boost-urls-url_view_base[url_view_base];
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-authority[`pass:v[authority]`] |
pass:v,q[Return the authority]

|xref:boost-urls-url_view_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the url string]

|xref:boost-urls-url_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing this with another url]

|xref:boost-urls-url_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the url's character buffer]

|xref:boost-urls-url_view_base-digest[`pass:v[digest]`] |

|xref:boost-urls-url_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the url is empty]

|xref:boost-urls-url_view_base-encoded_authority[`pass:v[encoded_authority]`] |
pass:v,q[Return the authority.]

|xref:boost-urls-url_view_base-encoded_fragment[`pass:v[encoded_fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-encoded_host[`pass:v[encoded_host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_address[`pass:v[encoded_host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_and_port[`pass:v[encoded_host_and_port]`] |
pass:v,q[Return the host and port]

|xref:boost-urls-url_view_base-encoded_host_name[`pass:v[encoded_host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-encoded_origin[`pass:v[encoded_origin]`] |
pass:v,q[Return the origin]

|xref:boost-urls-url_view_base-encoded_params[`pass:v[encoded_params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-encoded_password[`pass:v[encoded_password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-encoded_path[`pass:v[encoded_path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-encoded_query[`pass:v[encoded_query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-encoded_resource[`pass:v[encoded_resource]`] |
pass:v,q[Return the resource]

|xref:boost-urls-url_view_base-encoded_segments[`pass:v[encoded_segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-encoded_target[`pass:v[encoded_target]`] |
pass:v,q[Return the target]

|xref:boost-urls-url_view_base-encoded_user[`pass:v[encoded_user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-encoded_userinfo[`pass:v[encoded_userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-encoded_zone_id[`pass:v[encoded_zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url_view_base-fragment[`pass:v[fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-has_authority[`pass:v[has_authority]`] |
pass:v,q[Return true if an authority is present]

|xref:boost-urls-url_view_base-has_fragment[`pass:v[has_fragment]`] |
pass:v,q[Return true if a fragment is present]

|xref:boost-urls-url_view_base-has_password[`pass:v[has_password]`] |
pass:v,q[Return true if a password is present]

|xref:boost-urls-url_view_base-has_port[`pass:v[has_port]`] |
pass:v,q[Return true if a port is present]

|xref:boost-urls-url_view_base-has_query[`pass:v[has_query]`] |
pass:v,q[Return true if a query is present]

|xref:boost-urls-url_view_base-has_scheme[`pass:v[has_scheme]`] |
pass:v,q[Return true a scheme is present]

|xref:boost-urls-url_view_base-has_userinfo[`pass:v[has_userinfo]`] |
pass:v,q[Return true if a userinfo is present]

|xref:boost-urls-url_view_base-host[`pass:v[host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_address[`pass:v[host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_ipv4_address[`pass:v[host_ipv4_address]`] |
pass:v,q[Return the host IPv4 address]

|xref:boost-urls-url_view_base-host_ipv6_address[`pass:v[host_ipv6_address]`] |
pass:v,q[Return the host IPv6 address]

|xref:boost-urls-url_view_base-host_ipvfuture[`pass:v[host_ipvfuture]`] |
pass:v,q[Return the host IPvFuture address]

|xref:boost-urls-url_view_base-host_name[`pass:v[host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-host_type[`pass:v[host_type]`] |
pass:v,q[Return the host type]

|xref:boost-urls-url_view_base-is_path_absolute[`pass:v[is_path_absolute]`] |
pass:v,q[Return true if the path is absolute]

|xref:boost-urls-url_view_base-2conversion[`pass:v[operator string_view]`] |
pass:v,q[Return the URL as a core::string_view]

|xref:boost-urls-url_view-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-url_view_base-params[`pass:v[params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-password[`pass:v[password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-path[`pass:v[path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-persist[`pass:v[persist]`] |
pass:v,q[Return a shared, persistent copy of the url]

|xref:boost-urls-url_view_base-port[`pass:v[port]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-port_number[`pass:v[port_number]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-query[`pass:v[query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-scheme[`pass:v[scheme]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-scheme_id[`pass:v[scheme_id]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-segments[`pass:v[segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-size[`pass:v[size]`] |
pass:v,q[Return the number of characters in the url]

|xref:boost-urls-url_view-2constructor[`pass:v[url_view]`] |
pass:v,q[Constructor]

|xref:boost-urls-url_view_base-user[`pass:v[user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-userinfo[`pass:v[userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-zone_id[`pass:v[zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url_view-2destructor[`pass:v[~url_view]`] |
pass:v,q[Destructor]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-8friend-02[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-05[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-03[`pass:v[operator<<]`] |

|xref:boost-urls-url_view_base-8friend-04[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-07c[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-073[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-06[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two URLs]

|===

== Description

pass:v,q[Objects of this type represent valid URL] pass:v,q[strings constructed from a parsed, external]
pass:v,q[character buffer whose storage is managed]
pass:v,q[by the caller. That is, it acts like a]
pass:v,q[`core::string_view` in terms of ownership.]
pass:v,q[The caller is responsible for ensuring]
pass:v,q[that the lifetime of the underlying]
pass:v,q[character buffer extends until it is no]
pass:v,q[longer referenced.]

=== Example 1
pass:v,q[Construction from a string parses the input]
pass:v,q[as a]
pass:v,q[URI-reference]
pass:v,q[and throws an]
pass:v,q[exception on error. Upon success, the]
pass:v,q[constructed object points to the passed]
pass:v,q[character buffer; ownership is not]
pass:v,q[transferred.]
[,cpp]
----
url_view u( "https://www.example.com/index.htm?text=none#a1" );
----

=== Example 2
pass:v,q[Parsing functions like]
xref:boost-urls-parse_uri_reference[parse_uri_reference]
pass:v,q[return a]
pass:v,q[result]
pass:v,q[containing either a valid]
xref:boost-urls-url_view-2constructor-0c[url_view]
pass:v,q[upon succcess, otherwise they]
pass:v,q[contain an error. The error can be converted to]
pass:v,q[an exception by the caller if desired:]
[,cpp]
----
system::result< url_view > rv = parse_uri_reference( "https://www.example.com/index.htm?text=none#a1" );
----

=== BNF
[,cpp]
----
URI-reference = URI / relative-ref

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

relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification

* link:https://tools.ietf.org/html/rfc3986[Uniform Resource Identifier (URI): Generic Syntax (rfc3986)]




[#boost-urls-url_view-2destructor]

= Function url_view::~url_view

pass:v,q[Destructor]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L110[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
~url_view() = default;
----

== Description

pass:v,q[Any params, segments, iterators, or] pass:v,q[other views which reference the same]
pass:v,q[underlying character buffer remain]
pass:v,q[valid.]



== Return Value

* `void` 





[#boost-urls-url_view-2constructor]

= Overload set url_view::url_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view() noexcept = default;
  xref:boost-urls-url_view-2constructor-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view(string_view s);
  xref:boost-urls-url_view-2constructor-025[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class String,
    class = enable_if<std::is_convertible<String, core::string_view>::value && !std::is_convertible<String *, url_view_base *>::value>::type>
url_view(const String& s);
  xref:boost-urls-url_view-2constructor-00[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view(const xref:boost-urls-url_view[url_view]& other) noexcept;
  xref:boost-urls-url_view-2constructor-024[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view(const xref:boost-urls-url_view_base[url_view_base]& other) noexcept;
  xref:boost-urls-url_view-2constructor-0a[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url_view-operator_assign]

= Overload set url_view::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_view[url_view]&
operator=(const xref:boost-urls-url_view[url_view]& other) noexcept;
  xref:boost-urls-url_view-operator_assign-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_view[url_view]&
operator=(const xref:boost-urls-url_view_base[url_view_base]& other) noexcept;
  xref:boost-urls-url_view-operator_assign-0f[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url_view-max_size]

= Function url_view::max_size

pass:v,q[Return the maximum number of characters possible]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L331[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
size_t
max_size() noexcept;
----

== Description

pass:v,q[This represents the largest number of] pass:v,q[characters that are possible in a url,]
pass:v,q[not including any null terminator.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-authority_view]

= Class authority_view

pass:v,q[A non-owning reference to a valid authority]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L82[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class authority_view;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-authority_view-2constructor[`pass:v[authority_view]`] |
pass:v,q[Construct from a string.]

pass:v,q[Constructor]

|xref:boost-urls-authority_view-buffer[`pass:v[buffer]`] |
pass:v,q[Return the complete authority]

|xref:boost-urls-authority_view-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing this with another authority]

|xref:boost-urls-authority_view-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the first character]

|xref:boost-urls-authority_view-empty[`pass:v[empty]`] |
pass:v,q[Return true if the authority is empty]

|xref:boost-urls-authority_view-encoded_host[`pass:v[encoded_host]`] |
pass:v,q[Return the host]

|xref:boost-urls-authority_view-encoded_host_address[`pass:v[encoded_host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-authority_view-encoded_host_and_port[`pass:v[encoded_host_and_port]`] |
pass:v,q[Return the host and port]

|xref:boost-urls-authority_view-encoded_host_name[`pass:v[encoded_host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-authority_view-encoded_password[`pass:v[encoded_password]`] |
pass:v,q[Return the password]

|xref:boost-urls-authority_view-encoded_user[`pass:v[encoded_user]`] |
pass:v,q[Return the user]

|xref:boost-urls-authority_view-encoded_userinfo[`pass:v[encoded_userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-authority_view-has_password[`pass:v[has_password]`] |
pass:v,q[Return true if a password is present]

|xref:boost-urls-authority_view-has_port[`pass:v[has_port]`] |
pass:v,q[Return true if a port is present]

|xref:boost-urls-authority_view-has_userinfo[`pass:v[has_userinfo]`] |
pass:v,q[Return true if a userinfo is present]

|xref:boost-urls-authority_view-host[`pass:v[host]`] |
pass:v,q[Return the host]

|xref:boost-urls-authority_view-host_address[`pass:v[host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-authority_view-host_ipv4_address[`pass:v[host_ipv4_address]`] |
pass:v,q[Return the host IPv4 address]

|xref:boost-urls-authority_view-host_ipv6_address[`pass:v[host_ipv6_address]`] |
pass:v,q[Return the host IPv6 address]

|xref:boost-urls-authority_view-host_ipvfuture[`pass:v[host_ipvfuture]`] |
pass:v,q[Return the host IPvFuture address]

|xref:boost-urls-authority_view-host_name[`pass:v[host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-authority_view-host_type[`pass:v[host_type]`] |
pass:v,q[Return the host type]

|xref:boost-urls-authority_view-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-authority_view-password[`pass:v[password]`] |
pass:v,q[Return the password]

|xref:boost-urls-authority_view-port[`pass:v[port]`] |
pass:v,q[Return the port]

|xref:boost-urls-authority_view-port_number[`pass:v[port_number]`] |
pass:v,q[Return the port]

|xref:boost-urls-authority_view-size[`pass:v[size]`] |
pass:v,q[Return the number of characters in the authority]

|xref:boost-urls-authority_view-user[`pass:v[user]`] |
pass:v,q[Return the user]

|xref:boost-urls-authority_view-userinfo[`pass:v[userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-authority_view-2destructor[`pass:v[~authority_view]`] |
pass:v,q[Destructor]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-authority_view-8friend-0c[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-authority_view-8friend-076[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-authority_view-8friend-0a[`pass:v[operator<<]`] |

|xref:boost-urls-authority_view-8friend-007[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-authority_view-8friend-00c[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-authority_view-8friend-0d[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|xref:boost-urls-authority_view-8friend-072[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]

|===

== Description

pass:v,q[Objects of this type represent valid authority] pass:v,q[strings constructed from a parsed, external]
pass:v,q[character buffer whose storage is managed]
pass:v,q[by the caller. That is, it acts like a]
pass:v,q[`core::string_view` in terms of ownership.]
pass:v,q[The caller is responsible for ensuring]
pass:v,q[that the lifetime of the underlying]
pass:v,q[character buffer extends until it is no]
pass:v,q[longer referenced.]

=== Example 1
pass:v,q[Construction from a string parses the input]
pass:v,q[as an]
pass:v,q[authority]
pass:v,q[and throws an]
pass:v,q[exception on error. Upon success, the]
pass:v,q[constructed object points to the passed]
pass:v,q[character buffer; ownership is not]
pass:v,q[transferred.]
[,cpp]
----
authority_view a( "user:pass@www.example.com:8080" );
----

=== Example 2
pass:v,q[The parsing function]
xref:boost-urls-parse_authority[parse_authority]
pass:v,q[returns]
pass:v,q[a]
pass:v,q[result]
pass:v,q[containing either a valid]
xref:boost-urls-authority_view-2constructor-0e[authority_view]
pass:v,q[upon succcess, otherwise it]
pass:v,q[contain an error. The error can be converted to]
pass:v,q[an exception by the caller if desired:]
[,cpp]
----
system::result< authority_view > rv = parse_authority( "user:pass@www.example.com:8080" );
----

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = user [ ":" [ password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )

host          = IP-literal / IPv4address / reg-name

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[3.2. Authority (rfc3986)]




[#boost-urls-authority_view-2destructor]

= Function authority_view::~authority_view

pass:v,q[Destructor]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L106[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
~authority_view();
----


[#boost-urls-authority_view-2constructor]

= Overload set authority_view::authority_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
authority_view() noexcept;
  xref:boost-urls-authority_view-2constructor-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Construct from a string.]


[source,cpp,subs="verbatim,macros,-callouts"]
----
authority_view(string_view s);
  xref:boost-urls-authority_view-2constructor-03[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
authority_view(const xref:boost-urls-authority_view[authority_view]&) noexcept = default;
  xref:boost-urls-authority_view-2constructor-04[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-authority_view-operator_assign]

= Function authority_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L168[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-authority_view[authority_view]&
operator=(const xref:boost-urls-authority_view[authority_view]&) noexcept = default;
----


[#boost-urls-authority_view-size]

= Function authority_view::size

pass:v,q[Return the number of characters in the authority]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L191[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
size() const noexcept;
----

== Description

pass:v,q[This function returns the number of] pass:v,q[characters in the authority.]

=== Example
[,cpp]
----
assert( authority_view( "user:pass@www.example.com:8080" ).size() == 30 );
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-authority_view-empty]

= Function authority_view::empty

pass:v,q[Return true if the authority is empty]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L210[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description

pass:v,q[An empty authority has an empty host,] pass:v,q[no userinfo, and no port.]

=== Example
[,cpp]
----
assert( authority_view( "" ).empty() );
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-authority_view-data]

= Function authority_view::data

pass:v,q[Return a pointer to the first character]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L225[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
data() const noexcept;
----

== Description

pass:v,q[This function returns a pointer to the] pass:v,q[beginning of the view, which is not]
pass:v,q[guaranteed to be null-terminated.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-authority_view-buffer]

= Function authority_view::buffer

pass:v,q[Return the complete authority]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L253[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
buffer() const noexcept;
----

== Description

pass:v,q[This function returns the authority] pass:v,q[as a percent-encoded string.]

=== Example
[,cpp]
----
assert( parse_authority( "www.example.com" ).value().buffer() == "www.example.com" );
----

=== BNF
[,cpp]
----
authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[3.2. Authority (rfc3986)]



== Return Value

* `string_view` 





[#boost-urls-authority_view-has_userinfo]

= Function authority_view::has_userinfo

pass:v,q[Return true if a userinfo is present]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L302[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_userinfo() const noexcept;
----

== Description

pass:v,q[This function returns true if this] pass:v,q[contains a userinfo.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).has_userinfo() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-authority_view-userinfo]

= Function authority_view::userinfo

pass:v,q[Return the userinfo]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L346[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
userinfo(StringToken&& token) const;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the userinfo (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).userinfo() == "jane-doe:pass" );
----

=== Complexity
pass:v,q[Linear in `this->userinfo().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-authority_view-encoded_userinfo]

= Function authority_view::encoded_userinfo

pass:v,q[Return the userinfo]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L396[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_userinfo() const noexcept;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the userinfo (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).encoded_userinfo() == "jane%2Ddoe:pass" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-authority_view-user]

= Function authority_view::user

pass:v,q[Return the user]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L443[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
user(StringToken&& token) const;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the user (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).user() == "jane-doe" );
----

=== Complexity
pass:v,q[Linear in `this->user().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-authority_view-encoded_user]

= Function authority_view::encoded_user

pass:v,q[Return the user]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L494[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_user() const noexcept;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the user (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).encoded_user() == "jane%2Ddoe" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-authority_view-has_password]

= Function authority_view::has_password

pass:v,q[Return true if a password is present]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L535[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_password() const noexcept;
----

== Description

pass:v,q[This function returns true if the] pass:v,q[userinfo is present and contains]
pass:v,q[a password.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).has_password() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-authority_view-password]

= Function authority_view::password

pass:v,q[Return the password]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L580[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
password(StringToken&& token) const;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the password (which]
pass:v,q[may be an empty string).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).password() == "pass" );
----

=== Complexity
pass:v,q[Linear in `this->password().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-authority_view-encoded_password]

= Function authority_view::encoded_password

pass:v,q[Return the password]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L627[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_password() const noexcept;
----

== Description

pass:v,q[This function returns the password portion] pass:v,q[of the userinfo as a percent-encoded string.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).encoded_password() == "pass" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-authority_view-host_type]

= Function authority_view::host_type

pass:v,q[Return the host type]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L662[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-host_type[host_type]
host_type() const noexcept;
----

== Description

pass:v,q[This function returns one of the] pass:v,q[following constants representing the]
pass:v,q[type of host present.]

* xref:boost-urls-host_type-ipv4[host_type::ipv4]

* xref:boost-urls-host_type-ipv6[host_type::ipv6]

* xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture]

* xref:boost-urls-host_type-name[host_type::name]

=== Example
[,cpp]
----
assert( url_view( "https://192.168.0.1/local.htm" ).host_type() == host_type::ipv4 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `host_type` 





[#boost-urls-authority_view-host]

= Function authority_view::host

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L701[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
host(StringToken&& token) const;
----

== Description

pass:v,q[This function returns the host portion] pass:v,q[of the authority as a string, or the]
pass:v,q[empty string if there is no authority.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).host() == "www-root.example.com" );
----

=== Complexity
pass:v,q[Linear in `this->host().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-authority_view-encoded_host]

= Function authority_view::encoded_host

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L743[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host() const noexcept;
----

== Description

pass:v,q[This function returns the host portion] pass:v,q[of the authority as a string, or the]
pass:v,q[empty string if there is no authority.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).encoded_host() == "www%2droot.example.com" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-authority_view-host_address]

= Function authority_view::host_address

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L796[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
host_address(StringToken&& token) const;
----

== Description

pass:v,q[The value returned by this function] pass:v,q[depends on the type of host returned]
pass:v,q[from the function]
xref:boost-urls-authority_view-host_type[host_type.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4,]
pass:v,q[then the IPv4 address string is returned.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6,]
pass:v,q[then the IPv6 address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture,]
pass:v,q[then the IPvFuture address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-name[host_type::name,]
pass:v,q[then the host name string is returned.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-none[host_type::none,]
pass:v,q[then an empty string is returned.]

=== Example
[,cpp]
----
assert( url_view( "https://[1::6:c0a8:1]/" ).host_address() == "1::6:c0a8:1" );
----

=== Complexity
pass:v,q[Linear in `this->host_address().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-authority_view-encoded_host_address]

= Function authority_view::encoded_host_address

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L857[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host_address() const noexcept;
----

== Description

pass:v,q[The value returned by this function] pass:v,q[depends on the type of host returned]
pass:v,q[from the function]
xref:boost-urls-authority_view-host_type[host_type.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4,]
pass:v,q[then the IPv4 address string is returned.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6,]
pass:v,q[then the IPv6 address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture,]
pass:v,q[then the IPvFuture address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-name[host_type::name,]
pass:v,q[then the host name string is returned.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-none[host_type::none,]
pass:v,q[then an empty string is returned.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).encoded_host_address() == "www%2droot.example.com" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-authority_view-host_ipv4_address]

= Function authority_view::host_ipv4_address

pass:v,q[Return the host IPv4 address]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L896[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-ipv4_address[ipv4_address]
host_ipv4_address() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipv4[host_type::ipv4,] pass:v,q[this function returns the address as]
pass:v,q[a value of type]
xref:boost-urls-ipv4_address[ipv4_address.]
pass:v,q[Otherwise, if the host type is not an IPv4]
pass:v,q[address, it returns a default-constructed]
pass:v,q[value which is equal to the unspecified]
pass:v,q[address "0.0.0.0".]

=== Example
[,cpp]
----
assert( url_view( "http://127.0.0.1/index.htm?user=win95" ).host_ipv4_address() == ipv4_address( "127.0.0.1" ) );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `ipv4_address` 





[#boost-urls-authority_view-host_ipv6_address]

= Function authority_view::host_ipv6_address

pass:v,q[Return the host IPv6 address]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L943[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-ipv6_address[ipv6_address]
host_ipv6_address() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipv6[host_type::ipv6,] pass:v,q[this function returns the address as]
pass:v,q[a value of type]
xref:boost-urls-ipv6_address[ipv6_address.]
pass:v,q[Otherwise, if the host type is not an IPv6]
pass:v,q[address, it returns a default-constructed]
pass:v,q[value which is equal to the unspecified]
pass:v,q[address "0:0:0:0:0:0:0:0".]

=== Example
[,cpp]
----
assert( url_view( "ftp://[::1]/" ).host_ipv6_address() == ipv6_address( "::1" ) );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `ipv6_address` 





[#boost-urls-authority_view-host_ipvfuture]

= Function authority_view::host_ipvfuture

pass:v,q[Return the host IPvFuture address]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L975[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
host_ipvfuture() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture,]
pass:v,q[this function returns the address as]
pass:v,q[a string.]
pass:v,q[Otherwise, if the host type is not an]
pass:v,q[IPvFuture address, it returns an]
pass:v,q[empty string.]

=== Example
[,cpp]
----
assert( url_view( "http://[v1fe.d:9]/index.htm" ).host_ipvfuture() == "v1fe.d:9" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
IPvFuture  = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `string_view` 





[#boost-urls-authority_view-host_name]

= Function authority_view::host_name

pass:v,q[Return the host name]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1013[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
host_name(StringToken&& token) const;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-name[host_type::name,] pass:v,q[this function returns the name as]
pass:v,q[a string.]
pass:v,q[Otherwise, if the host type is not an]
pass:v,q[name, it returns an empty string.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).host_name() == "www-root.example.com" );
----

=== Complexity
pass:v,q[Linear in `this->host_name().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-authority_view-encoded_host_name]

= Function authority_view::encoded_host_name

pass:v,q[Return the host name]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1057[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host_name() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-name[host_type::name,] pass:v,q[this function returns the name as]
pass:v,q[a string.]
pass:v,q[Otherwise, if the host type is not an]
pass:v,q[name, it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).encoded_host_name() == "www%2droot.example.com" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-authority_view-has_port]

= Function authority_view::has_port

pass:v,q[Return true if a port is present]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1098[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_port() const noexcept;
----

== Description

pass:v,q[This function returns true if an] pass:v,q[authority is present and contains a port.]

=== Example
[,cpp]
----
assert( url_view( "wss://www.example.com:443" ).has_port() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority   = [ userinfo "@" ] host [ ":" port ]

port        = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-authority_view-port]

= Function authority_view::port

pass:v,q[Return the port]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1133[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
port() const noexcept;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the port (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]

=== Example
[,cpp]
----
assert( url_view( "http://localhost.com:8080" ).port() == "8080" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
port        = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `string_view` 





[#boost-urls-authority_view-port_number]

= Function authority_view::port_number

pass:v,q[Return the port]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1168[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
uint16_t
port_number() const noexcept;
----

== Description

pass:v,q[If a port is present and the numerical] pass:v,q[value is representable, it is returned]
pass:v,q[as an unsigned integer. Otherwise, the]
pass:v,q[number zero is returned.]

=== Example
[,cpp]
----
assert( url_view( "http://localhost.com:8080" ).port_number() == 8080 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
port        = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `uint16_t` 





[#boost-urls-authority_view-encoded_host_and_port]

= Function authority_view::encoded_host_and_port

pass:v,q[Return the host and port]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1207[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host_and_port() const noexcept;
----

== Description

pass:v,q[If an authority is present, this] pass:v,q[function returns the host and optional]
pass:v,q[port as a string, which may be empty.]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com:8080/index.htm" ).encoded_host_and_port() == "www.example.com:8080" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2.  Host (rfc3986)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-authority_view-compare]

= Function authority_view::compare

pass:v,q[Return the result of comparing this with another authority]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1232[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
int
compare(const xref:boost-urls-authority_view[authority_view]& other) const noexcept;
----

== Description

pass:v,q[This function compares two authorities] pass:v,q[according to Syntax-Based comparison]
pass:v,q[algorithm.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-authority_view-8friend-00c]

= Friend operator==

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1246[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator==(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



[#boost-urls-authority_view-8friend-0c]

= Friend operator!=

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1266[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator!=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



[#boost-urls-authority_view-8friend-076]

= Friend operator<

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1286[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator<(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



[#boost-urls-authority_view-8friend-007]

= Friend operator<=

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1306[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator<=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



[#boost-urls-authority_view-8friend-0d]

= Friend operator>

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1326[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator>(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



[#boost-urls-authority_view-8friend-072]

= Friend operator>=

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1346[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator>=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



[#boost-urls-authority_view-8friend-0a]

= Friend operator<<



== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1358[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-authority_view[authority_view]& a);
----


[#boost-urls-parse_authority]

= Function parse_authority

pass:v,q[Parse an authority]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1432[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-authority_view[authority_view]>
parse_authority(string_view s) noexcept;
----

== Description

pass:v,q[This function parses a string according to] pass:v,q[the authority grammar below, and returns an]
xref:boost-urls-authority_view[authority_view]
pass:v,q[referencing the string.]
pass:v,q[Ownership of the string is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the lifetime of the string extends until the]
pass:v,q[view is no longer being accessed.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = user [ ":" [ password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )

host          = IP-literal / IPv4address / reg-name

port          = *DIGIT
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[3.2. Authority (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-ignore_case_t]

= Class ignore_case_t



== Synopsis

Declared in header `</boost/url/ignore_case.hpp#L19[boost/url/ignore_case.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct ignore_case_t;
----




[#boost-urls-ignore_case]

= ignore_case



== Synopsis

Declared in header `</boost/url/ignore_case.hpp#L31[boost/url/ignore_case.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-ignore_case_t[ignore_case_t] ignore_case;
----


[#boost-urls-ignore_case_param]

= Class ignore_case_param

pass:v,q[An optional parameter to determine case-sensitivity]


== Synopsis

Declared in header `</boost/url/ignore_case.hpp#L46[boost/url/ignore_case.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class ignore_case_param;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ignore_case_param-2constructor[`pass:v[ignore_case_param]`] |
pass:v,q[Constructor]

|xref:boost-urls-ignore_case_param-2conversion[`pass:v[operator bool]`] |
pass:v,q[True if an algorithm should ignore case]

|===

== Description

pass:v,q[Functions may use parameters of this type] pass:v,q[to allow the user to optionally indicate]
pass:v,q[that comparisons should be case-insensitive]
pass:v,q[when the value]
xref:boost-urls-ignore_case[ignore_case]
pass:v,q[is passed.]




[#boost-urls-ignore_case_param-2constructor]

= Overload set ignore_case_param::ignore_case_param

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ignore_case_param() noexcept = default;
  xref:boost-urls-ignore_case_param-2constructor-03[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ignore_case_param(xref:boost-urls-ignore_case_t[ignore_case_t]) noexcept;
  xref:boost-urls-ignore_case_param-2constructor-01[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-ignore_case_param-2conversion]

= Function ignore_case_param::operator bool

pass:v,q[True if an algorithm should ignore case]


== Synopsis

Declared in header `</boost/url/ignore_case.hpp#L108[boost/url/ignore_case.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator bool() const noexcept;
----

== Description

pass:v,q[Values of type `ignore_case_param`] pass:v,q[evaluate to true when constructed]
pass:v,q[with the constant]
xref:boost-urls-ignore_case[ignore_case.]
pass:v,q[Otherwise, they are default-constructed]
pass:v,q[and evaluate to `false`.]



== Return Value

* `bool` 





[#boost-urls-segments_encoded_base]

= Class segments_encoded_base

pass:v,q[Common functionality for containers]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L37[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class segments_encoded_base;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-segments_encoded_base-iterator[iterator]

|xref:boost-urls-segments_encoded_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_encoded_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-segments_encoded_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-segments_encoded_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_encoded_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type used to represent size.]

|xref:boost-urls-segments_encoded_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-back[`pass:v[back]`] |
pass:v,q[Return the last segment]

|xref:boost-urls-segments_encoded_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-segments_encoded_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-segments_encoded_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no segments]

|xref:boost-urls-segments_encoded_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-segments_encoded_base-front[`pass:v[front]`] |
pass:v,q[Return the first segment]

|xref:boost-urls-segments_encoded_base-is_absolute[`pass:v[is_absolute]`] |
pass:v,q[Returns true if this references an absolute path.]

|xref:boost-urls-segments_encoded_base-size[`pass:v[size]`] |
pass:v,q[Return the number of segments]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[This base class is used by the library] pass:v,q[to provide common member functions for]
pass:v,q[containers. This cannot be instantiated]
pass:v,q[directly; Instead, use one of the]
pass:v,q[containers or functions:]

=== Containers

* xref:boost-urls-segments_ref[segments_ref]

* xref:boost-urls-segments_view[segments_view]

* xref:boost-urls-segments_encoded_ref[segments_encoded_ref]

* xref:boost-urls-segments_encoded_view[segments_encoded_view]




[#boost-urls-segments_encoded_base-iterator]

= Class segments_encoded_base::iterator



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L20[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class iterator;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-iterator-difference_type[`pass:v[difference_type]`] |

|xref:boost-urls-segments_encoded_base-iterator-iterator_category[`pass:v[iterator_category]`] |

|xref:boost-urls-segments_encoded_base-iterator-pointer[`pass:v[pointer]`] |

|xref:boost-urls-segments_encoded_base-iterator-reference[`pass:v[reference]`] |

|xref:boost-urls-segments_encoded_base-iterator-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-iterator-2constructor[`pass:v[iterator]`] |
|xref:boost-urls-segments_encoded_base-iterator-operator_not_eq[`pass:v[operator!=]`] |

|xref:boost-urls-segments_encoded_base-iterator-operator_star[`pass:v[operator*]`] |

|xref:boost-urls-segments_encoded_base-iterator-operator_inc[`pass:v[operator++]`] |
|xref:boost-urls-segments_encoded_base-iterator-operator_dec[`pass:v[operator--]`] |
|xref:boost-urls-segments_encoded_base-iterator-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-segments_encoded_base-iterator-operator_assign[`pass:v[operator=]`] |

|xref:boost-urls-segments_encoded_base-iterator-operator_eq[`pass:v[operator==]`] |

|===



[#boost-urls-segments_encoded_base-iterator-value_type]

= segments_encoded_base::iterator::value_type



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L38[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-value_type[value_type];
----


[#boost-urls-segments_encoded_base-iterator-reference]

= segments_encoded_base::iterator::reference



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L40[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-reference[reference];
----


[#boost-urls-segments_encoded_base-iterator-pointer]

= segments_encoded_base::iterator::pointer



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L42[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using pointer = xref:boost-urls-segments_encoded_base-iterator-reference[reference];
----


[#boost-urls-segments_encoded_base-iterator-difference_type]

= segments_encoded_base::iterator::difference_type



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L43[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-segments_encoded_base-iterator-iterator_category]

= segments_encoded_base::iterator::iterator_category



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L44[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using iterator_category = bidirectional_iterator_tag;
----


[#boost-urls-segments_encoded_base-iterator-2constructor]

= Overload set segments_encoded_base::iterator::iterator

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator() = default;
  xref:boost-urls-segments_encoded_base-iterator-2constructor-06[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-segments_encoded_base-iterator[iterator]&) = default;
  xref:boost-urls-segments_encoded_base-iterator-2constructor-02[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_base-iterator-operator_assign]

= Function segments_encoded_base::iterator::operator=



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L49[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-segments_encoded_base-iterator[iterator]&
operator=(const xref:boost-urls-segments_encoded_base-iterator[iterator]&) = default;
----


[#boost-urls-segments_encoded_base-iterator-operator_star]

= Function segments_encoded_base::iterator::operator*



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L52[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator-reference[reference]
operator*() const noexcept;
----


[#boost-urls-segments_encoded_base-iterator-operator_ptr]

= Function segments_encoded_base::iterator::operator->



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L58[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator-pointer[pointer]
operator->() const noexcept;
----


[#boost-urls-segments_encoded_base-iterator-operator_inc]

= Overload set segments_encoded_base::iterator::operator++

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]&
operator++() noexcept;
  xref:boost-urls-segments_encoded_base-iterator-operator_inc-08[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]
operator++(int) noexcept;
  xref:boost-urls-segments_encoded_base-iterator-operator_inc-0e[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_base-iterator-operator_dec]

= Overload set segments_encoded_base::iterator::operator--

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]&
operator--() noexcept;
  xref:boost-urls-segments_encoded_base-iterator-operator_dec-00[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]
operator--(int) noexcept;
  xref:boost-urls-segments_encoded_base-iterator-operator_dec-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_base-iterator-operator_eq]

= Function segments_encoded_base::iterator::operator==



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L94[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(const xref:boost-urls-segments_encoded_base-iterator[iterator]& other) const noexcept;
----


[#boost-urls-segments_encoded_base-iterator-operator_not_eq]

= Function segments_encoded_base::iterator::operator!=



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L101[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(const xref:boost-urls-segments_encoded_base-iterator[iterator]& other) const noexcept;
----


[#boost-urls-segments_encoded_base-const_iterator]

= segments_encoded_base::const_iterator

xref:boost-urls-segments_encoded_base-iterator[iterator]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L83[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_iterator = xref:boost-urls-segments_encoded_base-iterator[iterator];
----


[#boost-urls-segments_encoded_base-value_type]

= segments_encoded_base::value_type

pass:v,q[The value type]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L96[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = string;
----

== Description

pass:v,q[Values of this type represent a segment] pass:v,q[where unique ownership is retained by]
pass:v,q[making a copy.]

=== Example
[,cpp]
----
segments_encoded_base::value_type ps( url_view( "/path/to/file.txt" ).encoded_segments().back() );
----



[#boost-urls-segments_encoded_base-reference]

= segments_encoded_base::reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L103[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = xref:boost-urls-pct_string_view[pct_string_view];
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-segments_encoded_base-const_reference]

= segments_encoded_base::const_reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L106[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_reference = xref:boost-urls-pct_string_view[pct_string_view];
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-segments_encoded_base-size_type]

= segments_encoded_base::size_type

pass:v,q[An unsigned integer type used to represent size.]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L110[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using size_type = size_t;
----


[#boost-urls-segments_encoded_base-difference_type]

= segments_encoded_base::difference_type

pass:v,q[A signed integer type used to represent differences.]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L114[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-segments_encoded_base-max_size]

= Function segments_encoded_base::max_size

pass:v,q[Return the maximum number of characters possible]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L131[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
size_t
max_size() noexcept;
----

== Description

pass:v,q[This represents the largest number of] pass:v,q[characters that are possible in a path,]
pass:v,q[not including any null terminator.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-segments_encoded_base-buffer]

= Function segments_encoded_base::buffer

pass:v,q[Return the referenced character buffer.]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L158[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
buffer() const noexcept;
----

== Description

pass:v,q[This function returns the character] pass:v,q[buffer referenced by the view.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).encoded_segments().buffer() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `pct_string_view` 





[#boost-urls-segments_encoded_base-is_absolute]

= Function segments_encoded_base::is_absolute

pass:v,q[Returns true if this references an absolute path.]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L178[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_absolute() const noexcept;
----

== Description

pass:v,q[Absolute paths always start with a] pass:v,q[forward slash ('/').]

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).encoded_segments().is_absolute() == true );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-segments_encoded_base-empty]

= Function segments_encoded_base::empty

pass:v,q[Return true if there are no segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L195[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( ! url_view( "/index.htm" ).encoded_segments().empty() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-segments_encoded_base-size]

= Function segments_encoded_base::size

pass:v,q[Return the number of segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L212[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
size() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).encoded_segments().size() == 3 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-segments_encoded_base-front]

= Function segments_encoded_base::front

pass:v,q[Return the first segment]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L244[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
front() const noexcept;
----

== Description

pass:v,q[This function returns a string with the] pass:v,q[first segment of the path without any]
pass:v,q[leading or trailing '/' separators.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Preconditions
[,cpp]
----
this->empty() == false
----

=== Effects
[,cpp]
----
return *begin();
----

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).encoded_segments().front() == "path" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `pct_string_view` 





[#boost-urls-segments_encoded_base-back]

= Function segments_encoded_base::back

pass:v,q[Return the last segment]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L281[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
back() const noexcept;
----

== Description

pass:v,q[This function returns a string with the] pass:v,q[last segment of the path without any]
pass:v,q[leading or trailing '/' separators.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Preconditions
[,cpp]
----
this->empty() == false
----

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).encoded_segments().back() == "file.txt" );
----

=== Preconditions
[,cpp]
----
this->empty() == false
----

=== Effects
[,cpp]
----
return *--end();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `pct_string_view` 





[#boost-urls-segments_encoded_base-begin]

= Function segments_encoded_base::begin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L294[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]
begin() const noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `this->front().size()` or] pass:v,q[constant if `this->empty()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-segments_encoded_base-end]

= Function segments_encoded_base::end

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L306[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]
end() const noexcept;
----

== Description


=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-segments_base]

= Class segments_base

pass:v,q[Common functionality for containers]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L37[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class segments_base;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-segments_base-iterator[iterator]

|xref:boost-urls-segments_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-segments_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-segments_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type used to represent size.]

|xref:boost-urls-segments_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-back[`pass:v[back]`] |
pass:v,q[Return the last segment]

|xref:boost-urls-segments_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-segments_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-segments_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no segments]

|xref:boost-urls-segments_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-segments_base-front[`pass:v[front]`] |
pass:v,q[Return the first segment]

|xref:boost-urls-segments_base-is_absolute[`pass:v[is_absolute]`] |
pass:v,q[Returns true if this references an absolute path.]

|xref:boost-urls-segments_base-size[`pass:v[size]`] |
pass:v,q[Return the number of segments]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[This base class is used by the library] pass:v,q[to provide common member functions for]
pass:v,q[containers. This cannot be instantiated]
pass:v,q[directly; Instead, use one of the]
pass:v,q[containers or functions:]

=== Containers

* xref:boost-urls-segments_ref[segments_ref]

* xref:boost-urls-segments_view[segments_view]

* xref:boost-urls-segments_encoded_ref[segments_encoded_ref]

* xref:boost-urls-segments_encoded_view[segments_encoded_view]




[#boost-urls-segments_base-iterator]

= Class segments_base::iterator



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L21[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class iterator;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-iterator-difference_type[`pass:v[difference_type]`] |

|xref:boost-urls-segments_base-iterator-iterator_category[`pass:v[iterator_category]`] |

|xref:boost-urls-segments_base-iterator-pointer[`pass:v[pointer]`] |

|xref:boost-urls-segments_base-iterator-reference[`pass:v[reference]`] |

|xref:boost-urls-segments_base-iterator-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-iterator-2constructor[`pass:v[iterator]`] |
|xref:boost-urls-segments_base-iterator-operator_not_eq[`pass:v[operator!=]`] |

|xref:boost-urls-segments_base-iterator-operator_star[`pass:v[operator*]`] |

|xref:boost-urls-segments_base-iterator-operator_inc[`pass:v[operator++]`] |
|xref:boost-urls-segments_base-iterator-operator_dec[`pass:v[operator--]`] |
|xref:boost-urls-segments_base-iterator-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-segments_base-iterator-operator_assign[`pass:v[operator=]`] |

|xref:boost-urls-segments_base-iterator-operator_eq[`pass:v[operator==]`] |

|===



[#boost-urls-segments_base-iterator-value_type]

= segments_base::iterator::value_type



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L38[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-value_type[value_type];
----


[#boost-urls-segments_base-iterator-reference]

= segments_base::iterator::reference



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L39[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-reference[reference];
----


[#boost-urls-segments_base-iterator-pointer]

= segments_base::iterator::pointer



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L40[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using pointer = xref:boost-urls-segments_base-iterator-reference[reference];
----


[#boost-urls-segments_base-iterator-difference_type]

= segments_base::iterator::difference_type



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L41[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-difference_type[difference_type];
----


[#boost-urls-segments_base-iterator-iterator_category]

= segments_base::iterator::iterator_category



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L43[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using iterator_category = bidirectional_iterator_tag;
----


[#boost-urls-segments_base-iterator-2constructor]

= Overload set segments_base::iterator::iterator

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator() = default;
  xref:boost-urls-segments_base-iterator-2constructor-0a[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-segments_base-iterator[iterator]&) = default;
  xref:boost-urls-segments_base-iterator-2constructor-00[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_base-iterator-operator_assign]

= Function segments_base::iterator::operator=



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L48[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-segments_base-iterator[iterator]&
operator=(const xref:boost-urls-segments_base-iterator[iterator]&) noexcept = default;
----


[#boost-urls-segments_base-iterator-operator_star]

= Function segments_base::iterator::operator*



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L52[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator-reference[reference]
operator*() const;
----


[#boost-urls-segments_base-iterator-operator_ptr]

= Function segments_base::iterator::operator->



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L56[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator-pointer[pointer]
operator->() const = delete;
----


[#boost-urls-segments_base-iterator-operator_inc]

= Overload set segments_base::iterator::operator++

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]&
operator++() noexcept;
  xref:boost-urls-segments_base-iterator-operator_inc-08[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]
operator++(int) noexcept;
  xref:boost-urls-segments_base-iterator-operator_inc-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_base-iterator-operator_dec]

= Overload set segments_base::iterator::operator--

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]&
operator--() noexcept;
  xref:boost-urls-segments_base-iterator-operator_dec-0f[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]
operator--(int) noexcept;
  xref:boost-urls-segments_base-iterator-operator_dec-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_base-iterator-operator_eq]

= Function segments_base::iterator::operator==



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L88[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(const xref:boost-urls-segments_base-iterator[iterator]& other) const noexcept;
----


[#boost-urls-segments_base-iterator-operator_not_eq]

= Function segments_base::iterator::operator!=



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L95[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(const xref:boost-urls-segments_base-iterator[iterator]& other) const noexcept;
----


[#boost-urls-segments_base-const_iterator]

= segments_base::const_iterator

xref:boost-urls-segments_base-iterator[iterator]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L80[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_iterator = xref:boost-urls-segments_base-iterator[iterator];
----


[#boost-urls-segments_base-value_type]

= segments_base::value_type

pass:v,q[The value type]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L93[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = string;
----

== Description

pass:v,q[Values of this type represent a segment] pass:v,q[where unique ownership is retained by]
pass:v,q[making a copy.]

=== Example
[,cpp]
----
segments_base::value_type ps( url_view( "/path/to/file.txt" ).segments().back() );
----



[#boost-urls-segments_base-reference]

= segments_base::reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L100[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = string;
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-segments_base-const_reference]

= segments_base::const_reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L103[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_reference = string;
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-segments_base-size_type]

= segments_base::size_type

pass:v,q[An unsigned integer type used to represent size.]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L107[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using size_type = size_t;
----


[#boost-urls-segments_base-difference_type]

= segments_base::difference_type

pass:v,q[A signed integer type used to represent differences.]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L111[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-segments_base-max_size]

= Function segments_base::max_size

pass:v,q[Return the maximum number of characters possible]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L128[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
size_t
max_size() noexcept;
----

== Description

pass:v,q[This represents the largest number of] pass:v,q[characters that are possible in a path,]
pass:v,q[not including any null terminator.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-segments_base-buffer]

= Function segments_base::buffer

pass:v,q[Return the referenced character buffer.]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L155[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
buffer() const noexcept;
----

== Description

pass:v,q[This function returns the character] pass:v,q[buffer referenced by the view.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).segments().buffer() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `pct_string_view` 





[#boost-urls-segments_base-is_absolute]

= Function segments_base::is_absolute

pass:v,q[Returns true if this references an absolute path.]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L175[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_absolute() const noexcept;
----

== Description

pass:v,q[Absolute paths always start with a] pass:v,q[forward slash ('/').]

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).segments().is_absolute() == true );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-segments_base-empty]

= Function segments_base::empty

pass:v,q[Return true if there are no segments]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L192[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( ! url_view( "/index.htm" ).segments().empty() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-segments_base-size]

= Function segments_base::size

pass:v,q[Return the number of segments]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L209[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
size() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).segments().size() == 3 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-segments_base-front]

= Function segments_base::front

pass:v,q[Return the first segment]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L241[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string
front() const noexcept;
----

== Description

pass:v,q[This function returns a string with the] pass:v,q[first segment of the path without any]
pass:v,q[leading or trailing '/' separators.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Preconditions
[,cpp]
----
this->empty() == false
----

=== Effects
[,cpp]
----
return *begin();
----

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).segments().front() == "path" );
----

=== Complexity
pass:v,q[Linear in `this->front().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `string` 





[#boost-urls-segments_base-back]

= Function segments_base::back

pass:v,q[Return the last segment]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L272[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string
back() const noexcept;
----

== Description


=== Preconditions
[,cpp]
----
this->empty() == false
----

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).segments().back() == "file.txt" );
----

=== Preconditions
[,cpp]
----
this->empty() == false
----

=== Effects
[,cpp]
----
return *--end();
----

=== Complexity
pass:v,q[Linear in `this->back().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `string` 





[#boost-urls-segments_base-begin]

= Function segments_base::begin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L285[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]
begin() const noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `this->front().size()` or] pass:v,q[constant if `this->empty()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-segments_base-end]

= Function segments_base::end

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L297[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]
end() const noexcept;
----

== Description


=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-segments_view]

= Class segments_view

pass:v,q[A view representing path segments in a URL]


== Synopsis

Declared in header `</boost/url/segments_view.hpp#L55[boost/url/segments_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class segments_view
    : public xref:boost-urls-segments_base[segments_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-segments_base-iterator[iterator]

|xref:boost-urls-segments_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-segments_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-segments_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type used to represent size.]

|xref:boost-urls-segments_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-back[`pass:v[back]`] |
pass:v,q[Return the last segment]

|xref:boost-urls-segments_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-segments_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-segments_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no segments]

|xref:boost-urls-segments_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-segments_base-front[`pass:v[front]`] |
pass:v,q[Return the first segment]

|xref:boost-urls-segments_base-is_absolute[`pass:v[is_absolute]`] |
pass:v,q[Returns true if this references an absolute path.]

|xref:boost-urls-segments_view-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-segments_view-2constructor[`pass:v[segments_view]`] |
pass:v,q[Constructor]

|xref:boost-urls-segments_base-size[`pass:v[size]`] |
pass:v,q[Return the number of segments]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the path as a bidirectional view of segment]
pass:v,q[strings.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[character buffer. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the buffer]
pass:v,q[extends until it is no longer referenced.]

=== Example
[,cpp]
----
url_view u( "/path/to/file.txt" );

segments_view ps = u.segments();

assert( ps.buffer().data() == u.buffer().data() );
----
pass:v,q[Percent escapes in strings returned when]
pass:v,q[dereferencing iterators are automatically]
pass:v,q[decoded.]

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]




[#boost-urls-segments_view-2constructor]

= Overload set segments_view::segments_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_view() = default;
  xref:boost-urls-segments_view-2constructor-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_view(const xref:boost-urls-segments_view[segments_view]& other) = default;
  xref:boost-urls-segments_view-2constructor-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
segments_view(string_view s);
  xref:boost-urls-segments_view-2constructor-0e[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_view-operator_assign]

= Function segments_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/segments_view.hpp#L188[boost/url/segments_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-segments_view[segments_view]&
operator=(const xref:boost-urls-segments_view[segments_view]& other) = default;
----

== Description

pass:v,q[After assignment, both views] pass:v,q[reference the same underlying character]
pass:v,q[buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-segments_encoded_view]

= Class segments_encoded_view

pass:v,q[A view representing path segments in a URL]


== Synopsis

Declared in header `</boost/url/segments_encoded_view.hpp#L61[boost/url/segments_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class segments_encoded_view
    : public xref:boost-urls-segments_encoded_base[segments_encoded_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-segments_encoded_base-iterator[iterator]

|xref:boost-urls-segments_encoded_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_encoded_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-segments_encoded_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-segments_encoded_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_encoded_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type used to represent size.]

|xref:boost-urls-segments_encoded_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-back[`pass:v[back]`] |
pass:v,q[Return the last segment]

|xref:boost-urls-segments_encoded_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-segments_encoded_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-segments_encoded_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no segments]

|xref:boost-urls-segments_encoded_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-segments_encoded_base-front[`pass:v[front]`] |
pass:v,q[Return the first segment]

|xref:boost-urls-segments_encoded_base-is_absolute[`pass:v[is_absolute]`] |
pass:v,q[Returns true if this references an absolute path.]

|xref:boost-urls-segments_encoded_view-2conversion[`pass:v[operator segments_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-segments_encoded_view-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-segments_encoded_view-2constructor[`pass:v[segments_encoded_view]`] |
pass:v,q[Constructor]

|xref:boost-urls-segments_encoded_base-size[`pass:v[size]`] |
pass:v,q[Return the number of segments]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_view-8friend[`pass:v[parse_path]`] |

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the path as a bidirectional view of segment]
pass:v,q[strings.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[character buffer. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the buffer]
pass:v,q[extends until it is no longer referenced.]

=== Example
[,cpp]
----
url_view u( "/path/to/file.txt" );

segments_encoded_view ps = u.encoded_segments();

assert( ps.buffer().data() == u.buffer().data() );
----
pass:v,q[Strings produced when elements are returned]
pass:v,q[have type]
xref:boost-urls-param_pct_view[param_pct_view]
pass:v,q[and represent]
pass:v,q[encoded strings. Strings passed to member]
pass:v,q[functions may contain percent escapes, and]
pass:v,q[throw exceptions on invalid inputs.]

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]




[#boost-urls-segments_encoded_view-2constructor]

= Overload set segments_encoded_view::segments_encoded_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_encoded_view() = default;
  xref:boost-urls-segments_encoded_view-2constructor-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_encoded_view(const xref:boost-urls-segments_encoded_view[segments_encoded_view]&) noexcept = default;
  xref:boost-urls-segments_encoded_view-2constructor-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
segments_encoded_view(string_view s);
  xref:boost-urls-segments_encoded_view-2constructor-02[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_view-operator_assign]

= Function segments_encoded_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/segments_encoded_view.hpp#L192[boost/url/segments_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-segments_encoded_view[segments_encoded_view]&
operator=(const xref:boost-urls-segments_encoded_view[segments_encoded_view]&) = default;
----

== Description

pass:v,q[After assignment, both views] pass:v,q[reference the same underlying character]
pass:v,q[buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| **
| ``

|===




[#boost-urls-segments_encoded_view-2conversion]

= Function segments_encoded_view::operator segments_view

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/segments_encoded_view.hpp#L226[boost/url/segments_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-segments_view[segments_view]() const noexcept;
----

== Description

pass:v,q[This conversion returns a new view which] pass:v,q[references the same underlying character]
pass:v,q[buffer, and whose iterators and members]
pass:v,q[return ordinary strings with decoding]
pass:v,q[applied to any percent escapes.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Example
[,cpp]
----
segments_view ps = parse_path( "/path/to/file.txt" ).value();
----

=== Postconditions
[,cpp]
----
segments_view( *this ).buffer().data() == this->buffer().data()
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `segments_view` 





[#boost-urls-segments_encoded_view-8friend]

= Friend parse_path



== Synopsis

Declared in header `</boost/url/segments_encoded_view.hpp#L232[boost/url/segments_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
result<xref:boost-urls-segments_encoded_view[segments_encoded_view]>
parse_path(string_view s) noexcept;
----


[#boost-urls-parse_path]

= Function parse_path

pass:v,q[Parse a string and return an encoded segment view]


== Synopsis

Declared in header `</boost/url/parse_path.hpp#L48[boost/url/parse_path.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-segments_encoded_view[segments_encoded_view]>
parse_path(string_view s) noexcept;
----

== Description

pass:v,q[This function parses the string and returns the] pass:v,q[corresponding path object if the string is valid,]
pass:v,q[otherwise returns an error.]

=== BNF
[,cpp]
----
path          = [ "/" ] segment *( "/" segment )
----

=== Exception Safety
pass:v,q[No-throw guarantee.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-authority_rule_t]

= Class authority_rule_t



== Synopsis

Declared in header `</boost/url/rfc/authority_rule.hpp#L50[boost/url/rfc/authority_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct authority_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-authority_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-authority_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-authority_rule_t-value_type]

= authority_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/authority_rule.hpp#L52[boost/url/rfc/authority_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-authority_view[authority_view];
----


[#boost-urls-authority_rule_t-parse]

= Function authority_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/authority_rule.hpp#L55[boost/url/rfc/authority_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-authority_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-authority_rule]

= authority_rule



== Synopsis

Declared in header `</boost/url/rfc/authority_rule.hpp#L63[boost/url/rfc/authority_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-authority_rule_t[authority_rule_t] authority_rule;
----


[#boost-urls-pct_encoded_rule_t]

= Class pct_encoded_rule_t



== Synopsis

Declared in header `</boost/url/rfc/pct_encoded_rule.hpp#L69[boost/url/rfc/pct_encoded_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
struct pct_encoded_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-pct_encoded_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-pct_encoded_rule_t-parse[`pass:v[parse]`] |

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-pct_encoded_rule_t-8friend[`pass:v[pct_encoded_rule]`] |

|===



[#boost-urls-pct_encoded_rule_t-value_type]

= pct_encoded_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/pct_encoded_rule.hpp#L71[boost/url/rfc/pct_encoded_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-pct_string_view[pct_string_view];
----


[#boost-urls-pct_encoded_rule_t-8friend]

= Friend pct_encoded_rule



== Synopsis

Declared in header `</boost/url/rfc/pct_encoded_rule.hpp#L73[boost/url/rfc/pct_encoded_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet_>
friend
constexpr
xref:boost-urls-pct_encoded_rule_t[pct_encoded_rule_t]<CharSet_>
pct_encoded_rule(const CharSet_& cs) noexcept;
----


[#boost-urls-pct_encoded_rule_t-parse]

= Function pct_encoded_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/pct_encoded_rule.hpp#L81[boost/url/rfc/pct_encoded_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-pct_encoded_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-pct_encoded_rule]

= Overload set pct_encoded_rule

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet_>
constexpr
xref:boost-urls-pct_encoded_rule_t[pct_encoded_rule_t]<CharSet_>
pct_encoded_rule(const CharSet_& cs) noexcept;
  xref:boost-urls-pct_encoded_rule-09[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
constexpr
xref:boost-urls-pct_encoded_rule_t[pct_encoded_rule_t]<CharSet>
pct_encoded_rule(const CharSet& cs) noexcept;
  xref:boost-urls-pct_encoded_rule-08[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-variant]

= variant

pass:v,q[The type of variant used by the library]


== Synopsis

Declared in header `</boost/url/variant.hpp#L22[boost/url/variant.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class... Ts>
using variant = variant<Ts...>;
----


[#boost-urls-optional]

= optional



== Synopsis

Declared in header `</boost/url/optional.hpp#L39[boost/url/optional.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class T>
using optional = optional<T>;
----


[#boost-urls-params_encoded_base]

= Class params_encoded_base

pass:v,q[Common functionality for containers]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L38[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class params_encoded_base;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-params_encoded_base-iterator[iterator]

|xref:boost-urls-params_encoded_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_encoded_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-params_encoded_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-params_encoded_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_encoded_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type to represent sizes.]

|xref:boost-urls-params_encoded_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-params_encoded_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the query corresponding to these params]

|xref:boost-urls-params_encoded_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if a matching key exists]

|xref:boost-urls-params_encoded_base-count[`pass:v[count]`] |
pass:v,q[Return the number of matching keys]

|xref:boost-urls-params_encoded_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no params]

|xref:boost-urls-params_encoded_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-params_encoded_base-find[`pass:v[find]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_encoded_base-find_last[`pass:v[find_last]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_encoded_base-size[`pass:v[size]`] |
pass:v,q[Return the number of params]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[This base class is used by the library] pass:v,q[to provide common member functions for]
pass:v,q[containers. This cannot be instantiated]
pass:v,q[directly; Instead, use one of the]
pass:v,q[containers or functions:]

=== Containers

* xref:boost-urls-params_ref[params_ref]

* xref:boost-urls-params_view[params_view]

* xref:boost-urls-params_encoded_ref[params_encoded_ref]

* xref:boost-urls-params_encoded_view[params_encoded_view]




[#boost-urls-params_encoded_base-iterator]

= Class params_encoded_base::iterator



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L25[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class iterator;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-iterator-difference_type[`pass:v[difference_type]`] |

|xref:boost-urls-params_encoded_base-iterator-iterator_category[`pass:v[iterator_category]`] |

|xref:boost-urls-params_encoded_base-iterator-pointer[`pass:v[pointer]`] |

|xref:boost-urls-params_encoded_base-iterator-reference[`pass:v[reference]`] |

|xref:boost-urls-params_encoded_base-iterator-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-iterator-2constructor[`pass:v[iterator]`] |
|xref:boost-urls-params_encoded_base-iterator-operator_star[`pass:v[operator*]`] |

|xref:boost-urls-params_encoded_base-iterator-operator_inc[`pass:v[operator++]`] |
|xref:boost-urls-params_encoded_base-iterator-operator_dec[`pass:v[operator--]`] |
|xref:boost-urls-params_encoded_base-iterator-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-params_encoded_base-iterator-operator_assign[`pass:v[operator=]`] |

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-iterator-8friend-097[`pass:v[operator!=]`] |

|xref:boost-urls-params_encoded_base-iterator-8friend-09e[`pass:v[operator==]`] |

|===



[#boost-urls-params_encoded_base-iterator-value_type]

= params_encoded_base::iterator::value_type



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L41[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-value_type[value_type];
----


[#boost-urls-params_encoded_base-iterator-reference]

= params_encoded_base::iterator::reference



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L43[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-reference[reference];
----


[#boost-urls-params_encoded_base-iterator-pointer]

= params_encoded_base::iterator::pointer



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L45[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using pointer = xref:boost-urls-params_encoded_base-iterator-reference[reference];
----


[#boost-urls-params_encoded_base-iterator-difference_type]

= params_encoded_base::iterator::difference_type



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L46[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-params_encoded_base-iterator-iterator_category]

= params_encoded_base::iterator::iterator_category



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L47[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using iterator_category = bidirectional_iterator_tag;
----


[#boost-urls-params_encoded_base-iterator-2constructor]

= Overload set params_encoded_base::iterator::iterator

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator() = default;
  xref:boost-urls-params_encoded_base-iterator-2constructor-0c[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-params_encoded_base-iterator[iterator]&) = default;
  xref:boost-urls-params_encoded_base-iterator-2constructor-0e[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_base-iterator-operator_assign]

= Function params_encoded_base::iterator::operator=



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L52[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]&
operator=(const xref:boost-urls-params_encoded_base-iterator[iterator]&) = default;
----


[#boost-urls-params_encoded_base-iterator-operator_inc]

= Overload set params_encoded_base::iterator::operator++

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]&
operator++() noexcept;
  xref:boost-urls-params_encoded_base-iterator-operator_inc-09[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
operator++(int) noexcept;
  xref:boost-urls-params_encoded_base-iterator-operator_inc-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_base-iterator-operator_dec]

= Overload set params_encoded_base::iterator::operator--

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]&
operator--() noexcept;
  xref:boost-urls-params_encoded_base-iterator-operator_dec-01[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
operator--(int) noexcept;
  xref:boost-urls-params_encoded_base-iterator-operator_dec-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_base-iterator-operator_star]

= Function params_encoded_base::iterator::operator*



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L85[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator-reference[reference]
operator*() const;
----


[#boost-urls-params_encoded_base-iterator-operator_ptr]

= Function params_encoded_base::iterator::operator->



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L91[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator-pointer[pointer]
operator->() const;
----


[#boost-urls-params_encoded_base-iterator-8friend-09e]

= Friend operator==



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L97[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator==(
    const xref:boost-urls-params_encoded_base-iterator[iterator]& it0,
    const xref:boost-urls-params_encoded_base-iterator[iterator]& it1) noexcept;
----


[#boost-urls-params_encoded_base-iterator-8friend-097]

= Friend operator!=



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L106[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator!=(
    const xref:boost-urls-params_encoded_base-iterator[iterator]& it0,
    const xref:boost-urls-params_encoded_base-iterator[iterator]& it1) noexcept;
----


[#boost-urls-params_encoded_base-const_iterator]

= params_encoded_base::const_iterator

xref:boost-urls-params_encoded_base-iterator[iterator]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L84[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_iterator = xref:boost-urls-params_encoded_base-iterator[iterator];
----


[#boost-urls-params_encoded_base-value_type]

= params_encoded_base::value_type

pass:v,q[The value type]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L100[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-param[param];
----

== Description

pass:v,q[Values of this type represent parameters] pass:v,q[whose strings retain unique ownership by]
pass:v,q[making a copy.]

=== Example
[,cpp]
----
params_encoded_view::value_type qp( *url_view( "?first=John&last=Doe" ).params().find( "first" ) );
----



[#boost-urls-params_encoded_base-reference]

= params_encoded_base::reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L110[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = xref:boost-urls-param_pct_view[param_pct_view];
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-params_encoded_base-const_reference]

= params_encoded_base::const_reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L113[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_reference = xref:boost-urls-param_pct_view[param_pct_view];
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-params_encoded_base-size_type]

= params_encoded_base::size_type

pass:v,q[An unsigned integer type to represent sizes.]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L117[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using size_type = size_t;
----


[#boost-urls-params_encoded_base-difference_type]

= params_encoded_base::difference_type

pass:v,q[A signed integer type used to represent differences.]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L121[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-params_encoded_base-max_size]

= Function params_encoded_base::max_size

pass:v,q[Return the maximum number of characters possible]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L138[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
size_t
max_size() noexcept;
----

== Description

pass:v,q[This represents the largest number of] pass:v,q[characters that are possible in a path,]
pass:v,q[not including any null terminator.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-params_encoded_base-buffer]

= Function params_encoded_base::buffer

pass:v,q[Return the query corresponding to these params]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L176[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
buffer() const noexcept;
----

== Description

pass:v,q[This function returns the query string] pass:v,q[referenced by the container.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).encoded_params().buffer() == "first=John&last=Doe" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query-params    = query-param *( "&" query-param )
query-param     = key [ "=" value ]
key             = *qpchar
value           = *( qpchar / "=" )
----

=== Specification

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `pct_string_view` 





[#boost-urls-params_encoded_base-empty]

= Function params_encoded_base::empty

pass:v,q[Return true if there are no params]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L192[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( ! url_view( "?key=value" ).encoded_params().empty() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-params_encoded_base-size]

= Function params_encoded_base::size

pass:v,q[Return the number of params]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L208[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
size() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( url_view( "?key=value").encoded_params().size() == 1 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-params_encoded_base-begin]

= Function params_encoded_base::begin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L219[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
begin() const noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in the size of the first param.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-params_encoded_base-end]

= Function params_encoded_base::end

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L230[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
end() const noexcept;
----

== Description


=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-params_encoded_base-contains]

= Function params_encoded_base::contains

pass:v,q[Return true if a matching key exists]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L267[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
contains(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find a match for]
pass:v,q[the specified key,]
pass:v,q[which may contain percent escapes.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).encoded_params().contains( "first" ) );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_encoded_base-count]

= Function params_encoded_base::count

pass:v,q[Return the number of matching keys]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L304[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
count(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find the number of]
pass:v,q[matches for the specified key,]
pass:v,q[which may contain percent escapes.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).encoded_params().count( "first" ) == 1 );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `size_t` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_encoded_base-find]

= Overload set params_encoded_base::find

== Members


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_encoded_base-find-03[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find(
    xref:boost-urls-params_encoded_base-iterator[iterator] from,
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_encoded_base-find-00[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_base-find_last]

= Overload set params_encoded_base::find_last

== Members


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find_last(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_encoded_base-find_last-05[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find_last(
    xref:boost-urls-params_encoded_base-iterator[iterator] before,
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_encoded_base-find_last-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref]

= Class params_ref

pass:v,q[A view representing query parameters in a URL]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L80[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class params_ref
    : public xref:boost-urls-params_base[params_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-params_base-iterator[iterator]

|xref:boost-urls-params_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-params_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-params_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type to represent sizes.]

|xref:boost-urls-params_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_ref-append[`pass:v[append]`] |
pass:v,q[Append elements]

|xref:boost-urls-params_ref-assign[`pass:v[assign]`] |
pass:v,q[Assign elements]

|xref:boost-urls-params_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-params_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-params_ref-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents of the container]

|xref:boost-urls-params_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if a matching key exists]

|xref:boost-urls-params_base-count[`pass:v[count]`] |
pass:v,q[Return the number of matching keys]

|xref:boost-urls-params_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no params]

|xref:boost-urls-params_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-params_ref-erase[`pass:v[erase]`] |
pass:v,q[Erase elements]

|xref:boost-urls-params_base-find[`pass:v[find]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_base-find_last[`pass:v[find_last]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_ref-insert[`pass:v[insert]`] |
pass:v,q[Insert elements]

|xref:boost-urls-params_ref-2conversion[`pass:v[operator params_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-params_ref-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-params_ref-2constructor[`pass:v[params_ref]`] |
pass:v,q[Constructor]

|xref:boost-urls-params_ref-replace[`pass:v[replace]`] |
pass:v,q[Replace elements]

|xref:boost-urls-params_ref-set[`pass:v[set]`] |
pass:v,q[Set a value]

|xref:boost-urls-params_base-size[`pass:v[size]`] |
pass:v,q[Return the number of params]

|xref:boost-urls-params_ref-unset[`pass:v[unset]`] |
pass:v,q[Remove the value on an element]

|xref:boost-urls-params_ref-url[`pass:v[url]`] |
pass:v,q[Return the referenced url]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the query parameters as a bidirectional view]
pass:v,q[of key/value pairs.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[url. The caller is responsible for ensuring]
pass:v,q[that the lifetime of the referenced url]
pass:v,q[extends until it is no longer referenced.]
pass:v,q[The view is modifiable; calling non-const]
pass:v,q[members causes changes to the referenced]
pass:v,q[url.]
pass:v,q[Percent escapes in strings returned when]
pass:v,q[dereferencing iterators are automatically]
pass:v,q[decoded.]
pass:v,q[Reserved characters in strings supplied]
pass:v,q[to modifier functions are automatically]
pass:v,q[percent-escaped.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

params_ref p = u.params();
----

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]
pass:v,q[Modifications made through the container]
pass:v,q[invalidate some or all iterators:]

* xref:boost-urls-params_ref-append-0f[append]
pass:v,q[: Only `end()`.]

* xref:boost-urls-params_ref-assign-09[assign,]
xref:boost-urls-params_ref-clear[clear,]
pass:v,q[`operator=` : All elements.]

* xref:boost-urls-params_ref-erase-05[erase]
pass:v,q[: Erased elements and all]
pass:v,q[elements after (including `end()`).]

* xref:boost-urls-params_ref-insert-08[insert]
pass:v,q[: All elements at or after]
pass:v,q[the insertion point (including `end()`).]

* xref:boost-urls-params_ref-replace-0d[replace,]
xref:boost-urls-params_ref-set-01[set]
pass:v,q[: Modified]
pass:v,q[elements and all elements]
pass:v,q[after (including `end()`).]




[#boost-urls-params_ref-2constructor]

= Overload set params_ref::params_ref

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_ref(const xref:boost-urls-params_ref[params_ref]& other) = default;
  xref:boost-urls-params_ref-2constructor-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
params_ref(
    const xref:boost-urls-params_ref[params_ref]& other,
    xref:boost-urls-encoding_opts[encoding_opts] opt) noexcept;
  xref:boost-urls-params_ref-2constructor-09[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref-operator_assign]

= Overload set params_ref::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]&
operator=(const xref:boost-urls-params_ref[params_ref]& other);
  xref:boost-urls-params_ref-operator_assign-0c[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]&
operator=(initializer_list<xref:boost-urls-param_view[param_view]> init);
  xref:boost-urls-params_ref-operator_assign-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref-2conversion]

= Function params_ref::operator params_view

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L221[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-params_view[params_view]() const noexcept;
----


[#boost-urls-params_ref-url]

= Function params_ref::url

pass:v,q[Return the referenced url]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L247[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
url() const noexcept;
----

== Description

pass:v,q[This function returns the url referenced] pass:v,q[by the view.]

=== Example
[,cpp]
----
url u( "?key=value" );

assert( &u.segments().url() == &u );
----

=== Exception Safety
[,cpp]
----
Throws nothing.
----



== Return Value

* `` 





[#boost-urls-params_ref-clear]

= Function params_ref::clear

pass:v,q[Clear the contents of the container]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L280[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
clear() noexcept;
----

== Description

pass:v,q[All iterators are invalidated.]

=== Effects
[,cpp]
----
this->url().remove_query();
----

=== Postconditions
[,cpp]
----
this->empty() == true && this->url().has_query() == false
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-params_ref-assign]

= Overload set params_ref::assign

== Members


pass:v,q[Assign elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<xref:boost-urls-param_view[param_view]> init);
  xref:boost-urls-params_ref-assign-09[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assign elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_ref-assign-02[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref-append]

= Overload set params_ref::append

== Members


pass:v,q[Append elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
append(const xref:boost-urls-param_view[param_view]& p);
  xref:boost-urls-params_ref-append-0f[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Append elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
append(initializer_list<xref:boost-urls-param_view[param_view]> init);
  xref:boost-urls-params_ref-append-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Append elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
append(
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_ref-append-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref-insert]

= Overload set params_ref::insert

== Members


pass:v,q[Insert elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
insert(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] before,
    const xref:boost-urls-param_view[param_view]& p);
  xref:boost-urls-params_ref-insert-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
insert(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] before,
    initializer_list<xref:boost-urls-param_view[param_view]> init);
  xref:boost-urls-params_ref-insert-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
insert(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_ref-insert-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref-erase]

= Overload set params_ref::erase

== Members


pass:v,q[Erase elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
erase(xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] pos) noexcept;
  xref:boost-urls-params_ref-erase-05[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Erase elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
erase(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] first,
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] last) noexcept;
  xref:boost-urls-params_ref-erase-0f[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Erase elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
erase(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) noexcept;
  xref:boost-urls-params_ref-erase-00[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref-replace]

= Overload set params_ref::replace

== Members


pass:v,q[Replace elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
replace(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] pos,
    const xref:boost-urls-param_view[param_view]& p);
  xref:boost-urls-params_ref-replace-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
replace(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] from,
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] to,
    initializer_list<xref:boost-urls-param_view[param_view]> init);
  xref:boost-urls-params_ref-replace-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace elements]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
replace(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] from,
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_ref-replace-01[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_ref-unset]

= Function params_ref::unset

pass:v,q[Remove the value on an element]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L810[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
unset(xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] pos) noexcept;
----

== Description

pass:v,q[This function removes the value of] pass:v,q[an element at the specified position.]
pass:v,q[After the call returns, `has_value`]
pass:v,q[for the element is false.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

u.params().unset( u.params().begin() );

assert( u.encoded_query() == "first&last=Doe" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

|===




[#boost-urls-params_ref-set]

= Overload set params_ref::set

== Members


pass:v,q[Set a value]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
set(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] pos,
    string_view value);
  xref:boost-urls-params_ref-set-09[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Set a value]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
set(
    string_view key,
    string_view value,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {});
  xref:boost-urls-params_ref-set-01[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_base]

= Class params_base

pass:v,q[Common functionality for containers]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L39[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class params_base;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-params_base-iterator[iterator]

|xref:boost-urls-params_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-params_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-params_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type to represent sizes.]

|xref:boost-urls-params_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-params_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-params_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if a matching key exists]

|xref:boost-urls-params_base-count[`pass:v[count]`] |
pass:v,q[Return the number of matching keys]

|xref:boost-urls-params_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no params]

|xref:boost-urls-params_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-params_base-find[`pass:v[find]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_base-find_last[`pass:v[find_last]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_base-size[`pass:v[size]`] |
pass:v,q[Return the number of params]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[This base class is used by the library] pass:v,q[to provide common member functions for]
pass:v,q[containers. This cannot be instantiated]
pass:v,q[directly; Instead, use one of the]
pass:v,q[containers or functions:]

=== Containers

* xref:boost-urls-params_ref[params_ref]

* xref:boost-urls-params_view[params_view]

* xref:boost-urls-params_encoded_ref[params_encoded_ref]

* xref:boost-urls-params_encoded_view[params_encoded_view]




[#boost-urls-params_base-iterator]

= Class params_base::iterator



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L22[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class iterator;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-iterator-difference_type[`pass:v[difference_type]`] |

|xref:boost-urls-params_base-iterator-iterator_category[`pass:v[iterator_category]`] |

|xref:boost-urls-params_base-iterator-pointer[`pass:v[pointer]`] |

|xref:boost-urls-params_base-iterator-reference[`pass:v[reference]`] |

|xref:boost-urls-params_base-iterator-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-iterator-2constructor[`pass:v[iterator]`] |
|xref:boost-urls-params_base-iterator-operator_not_eq[`pass:v[operator!=]`] |

|xref:boost-urls-params_base-iterator-operator_star[`pass:v[operator*]`] |

|xref:boost-urls-params_base-iterator-operator_inc[`pass:v[operator++]`] |
|xref:boost-urls-params_base-iterator-operator_dec[`pass:v[operator--]`] |
|xref:boost-urls-params_base-iterator-operator_ptr[`pass:v[operator->]`] |

|xref:boost-urls-params_base-iterator-operator_assign[`pass:v[operator=]`] |

|xref:boost-urls-params_base-iterator-operator_eq[`pass:v[operator==]`] |

|===



[#boost-urls-params_base-iterator-value_type]

= params_base::iterator::value_type



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L48[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-value_type[value_type];
----


[#boost-urls-params_base-iterator-reference]

= params_base::iterator::reference



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L49[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-reference[reference];
----


[#boost-urls-params_base-iterator-pointer]

= params_base::iterator::pointer



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L50[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using pointer = xref:boost-urls-params_base-iterator-reference[reference];
----


[#boost-urls-params_base-iterator-difference_type]

= params_base::iterator::difference_type



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L51[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-difference_type[difference_type];
----


[#boost-urls-params_base-iterator-iterator_category]

= params_base::iterator::iterator_category



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L53[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using iterator_category = bidirectional_iterator_tag;
----


[#boost-urls-params_base-iterator-2constructor]

= Overload set params_base::iterator::iterator

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator() = default;
  xref:boost-urls-params_base-iterator-2constructor-0c[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-params_base-iterator[iterator]&) = default;
  xref:boost-urls-params_base-iterator-2constructor-00[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_base-iterator-operator_assign]

= Function params_base::iterator::operator=



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L58[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]&
operator=(const xref:boost-urls-params_base-iterator[iterator]&) noexcept = default;
----


[#boost-urls-params_base-iterator-operator_inc]

= Overload set params_base::iterator::operator++

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]&
operator++() noexcept;
  xref:boost-urls-params_base-iterator-operator_inc-01[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
operator++(int) noexcept;
  xref:boost-urls-params_base-iterator-operator_inc-09[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_base-iterator-operator_dec]

= Overload set params_base::iterator::operator--

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]&
operator--() noexcept;
  xref:boost-urls-params_base-iterator-operator_dec-0c[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
operator--(int) noexcept;
  xref:boost-urls-params_base-iterator-operator_dec-08[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_base-iterator-operator_star]

= Function params_base::iterator::operator*



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L91[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator-reference[reference]
operator*() const;
----


[#boost-urls-params_base-iterator-operator_ptr]

= Function params_base::iterator::operator->



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L95[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator-pointer[pointer]
operator->() const = delete;
----


[#boost-urls-params_base-iterator-operator_eq]

= Function params_base::iterator::operator==



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L97[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(const xref:boost-urls-params_base-iterator[iterator]& other) const noexcept;
----


[#boost-urls-params_base-iterator-operator_not_eq]

= Function params_base::iterator::operator!=



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L104[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(const xref:boost-urls-params_base-iterator[iterator]& other) const noexcept;
----


[#boost-urls-params_base-const_iterator]

= params_base::const_iterator

xref:boost-urls-params_base-iterator[iterator]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L95[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_iterator = xref:boost-urls-params_base-iterator[iterator];
----


[#boost-urls-params_base-value_type]

= params_base::value_type

pass:v,q[The value type]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L111[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-param[param];
----

== Description

pass:v,q[Values of this type represent parameters] pass:v,q[whose strings retain unique ownership by]
pass:v,q[making a copy.]

=== Example
[,cpp]
----
params_view::value_type qp( *url_view( "?first=John&last=Doe" ).params().find( "first" ) );
----



[#boost-urls-params_base-reference]

= params_base::reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L121[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using reference = xref:boost-urls-param[param];
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-params_base-const_reference]

= params_base::const_reference

pass:v,q[The reference type]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L124[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using const_reference = xref:boost-urls-param[param];
----

== Description

pass:v,q[This is the type of value returned when] pass:v,q[iterators of the view are dereferenced.]



[#boost-urls-params_base-size_type]

= params_base::size_type

pass:v,q[An unsigned integer type to represent sizes.]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L128[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using size_type = size_t;
----


[#boost-urls-params_base-difference_type]

= params_base::difference_type

pass:v,q[A signed integer type used to represent differences.]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L132[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using difference_type = ptrdiff_t;
----


[#boost-urls-params_base-max_size]

= Function params_base::max_size

pass:v,q[Return the maximum number of characters possible]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L149[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
size_t
max_size() noexcept;
----

== Description

pass:v,q[This represents the largest number of] pass:v,q[characters that are possible in a path,]
pass:v,q[not including any null terminator.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-params_base-buffer]

= Function params_base::buffer

pass:v,q[Return the referenced character buffer.]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L175[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
buffer() const noexcept;
----

== Description

pass:v,q[This function returns the character] pass:v,q[buffer referenced by the view.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).params().buffer() == "?first=John&last=Doe" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `pct_string_view` 





[#boost-urls-params_base-empty]

= Function params_base::empty

pass:v,q[Return true if there are no params]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L191[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( ! url_view( "?key=value" ).params().empty() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 





[#boost-urls-params_base-size]

= Function params_base::size

pass:v,q[Return the number of params]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L207[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
size() const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( url_view( "?key=value").params().size() == 1 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-params_base-begin]

= Function params_base::begin

pass:v,q[Return an iterator to the beginning]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L218[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
begin() const noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in the size of the first param.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-params_base-end]

= Function params_base::end

pass:v,q[Return an iterator to the end]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L229[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
end() const noexcept;
----

== Description


=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 





[#boost-urls-params_base-contains]

= Function params_base::contains

pass:v,q[Return true if a matching key exists]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L262[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
contains(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find a match for]
pass:v,q[the specified key.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).params().contains( "first" ) );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_base-count]

= Function params_base::count

pass:v,q[Return the number of matching keys]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L296[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
count(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the] pass:v,q[parameters in the container to] pass:v,q[find the number of matches for]
pass:v,q[the specified key.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).params().count( "first" ) == 1 );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_base-find]

= Overload set params_base::find

== Members


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_base-find-09[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find(
    xref:boost-urls-params_base-iterator[iterator] from,
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_base-find-04[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_base-find_last]

= Overload set params_base::find_last

== Members


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find_last(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_base-find_last-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Find a matching key]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find_last(
    xref:boost-urls-params_base-iterator[iterator] before,
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
  xref:boost-urls-params_base-find_last-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_view]

= Class params_view

pass:v,q[A view representing query parameters in a URL]


== Synopsis

Declared in header `</boost/url/params_view.hpp#L47[boost/url/params_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class params_view
    : public xref:boost-urls-params_base[params_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-params_base-iterator[iterator]

|xref:boost-urls-params_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-params_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-params_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type to represent sizes.]

|xref:boost-urls-params_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-params_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-params_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if a matching key exists]

|xref:boost-urls-params_base-count[`pass:v[count]`] |
pass:v,q[Return the number of matching keys]

|xref:boost-urls-params_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no params]

|xref:boost-urls-params_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-params_base-find[`pass:v[find]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_base-find_last[`pass:v[find_last]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_view-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-params_view-2constructor[`pass:v[params_view]`] |
pass:v,q[Constructor]

|xref:boost-urls-params_base-size[`pass:v[size]`] |
pass:v,q[Return the number of params]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the query parameters as a bidirectional view]
pass:v,q[of key/value pairs.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[character buffer. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the buffer]
pass:v,q[extends until it is no longer referenced.]

=== Example
[,cpp]
----
url_view u( "?first=John&last=Doe" );

params_view p = u.params();
----
pass:v,q[Percent escapes in strings returned when]
pass:v,q[dereferencing iterators are automatically]
pass:v,q[decoded.]

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]




[#boost-urls-params_view-2constructor]

= Overload set params_view::params_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view() = default;
  xref:boost-urls-params_view-2constructor-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_view(const xref:boost-urls-params_view[params_view]& other) = default;
  xref:boost-urls-params_view-2constructor-091[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view(
    const xref:boost-urls-params_view[params_view]& other,
    xref:boost-urls-encoding_opts[encoding_opts] opt) noexcept;
  xref:boost-urls-params_view-2constructor-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view(string_view s);
  xref:boost-urls-params_view-2constructor-09a[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view(
    string_view s,
    xref:boost-urls-encoding_opts[encoding_opts] opt);
  xref:boost-urls-params_view-2constructor-04[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_view-operator_assign]

= Function params_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/params_view.hpp#L278[boost/url/params_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_view[params_view]&
operator=(const xref:boost-urls-params_view[params_view]&) = default;
----

== Description

pass:v,q[After assignment, both views reference] pass:v,q[the same underlying character buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| **
| ``

|===




[#boost-urls-params_encoded_view]

= Class params_encoded_view

pass:v,q[A view representing query parameters in a URL]


== Synopsis

Declared in header `</boost/url/params_encoded_view.hpp#L54[boost/url/params_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class params_encoded_view
    : public xref:boost-urls-params_encoded_base[params_encoded_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-params_encoded_base-iterator[iterator]

|xref:boost-urls-params_encoded_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_encoded_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-params_encoded_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-params_encoded_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_encoded_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type to represent sizes.]

|xref:boost-urls-params_encoded_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-params_encoded_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the query corresponding to these params]

|xref:boost-urls-params_encoded_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if a matching key exists]

|xref:boost-urls-params_encoded_base-count[`pass:v[count]`] |
pass:v,q[Return the number of matching keys]

|xref:boost-urls-params_encoded_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no params]

|xref:boost-urls-params_encoded_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-params_encoded_base-find[`pass:v[find]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_encoded_base-find_last[`pass:v[find_last]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_encoded_view-2conversion[`pass:v[operator params_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-params_encoded_view-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-params_encoded_view-2constructor[`pass:v[params_encoded_view]`] |
pass:v,q[Constructor]

|xref:boost-urls-params_encoded_base-size[`pass:v[size]`] |
pass:v,q[Return the number of params]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_view-8friend[`pass:v[parse_query]`] |

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the query parameters as a bidirectional view]
pass:v,q[of key/value pairs.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[character buffer. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the buffer]
pass:v,q[extends until it is no longer referenced.]

=== Example
[,cpp]
----
url_view u( "?first=John&last=Doe" );

params_encoded_view p = u.encoded_params();
----
pass:v,q[Strings produced when elements are returned]
pass:v,q[have type]
xref:boost-urls-param_pct_view[param_pct_view]
pass:v,q[and represent]
pass:v,q[encoded strings. Strings passed to member]
pass:v,q[functions may contain percent escapes, and]
pass:v,q[throw exceptions on invalid inputs.]

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]




[#boost-urls-params_encoded_view-2constructor]

= Overload set params_encoded_view::params_encoded_view

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_encoded_view() = default;
  xref:boost-urls-params_encoded_view-2constructor-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_encoded_view(const xref:boost-urls-params_encoded_view[params_encoded_view]& other) = default;
  xref:boost-urls-params_encoded_view-2constructor-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
params_encoded_view(string_view s);
  xref:boost-urls-params_encoded_view-2constructor-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_view-operator_assign]

= Function params_encoded_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/params_encoded_view.hpp#L190[boost/url/params_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-params_encoded_view[params_encoded_view]&
operator=(const xref:boost-urls-params_encoded_view[params_encoded_view]&) = default;
----

== Description

pass:v,q[After assignment, both views] pass:v,q[reference the same underlying character]
pass:v,q[buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| **
| ``

|===




[#boost-urls-params_encoded_view-2conversion]

= Function params_encoded_view::operator params_view

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/params_encoded_view.hpp#L223[boost/url/params_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-params_view[params_view]() const noexcept;
----

== Description

pass:v,q[This conversion returns a new view which] pass:v,q[references the same underlying character]
pass:v,q[buffer, and whose iterators and members]
pass:v,q[return ordinary strings with decoding]
pass:v,q[applied to any percent escapes.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Example
[,cpp]
----
params_view qp = parse_path( "/path/to/file.txt" ).value();
----

=== Postconditions
[,cpp]
----
params_view( *this ).buffer().data() == this->buffer().data()
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `params_view` 





[#boost-urls-params_encoded_view-8friend]

= Friend parse_query



== Synopsis

Declared in header `</boost/url/params_encoded_view.hpp#L228[boost/url/params_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
result<xref:boost-urls-params_encoded_view[params_encoded_view]>
parse_query(string_view s) noexcept;
----


[#boost-urls-parse_query]

= Function parse_query

pass:v,q[Parse a string and return an encoded params view]


== Synopsis

Declared in header `</boost/url/parse_query.hpp#L46[boost/url/parse_query.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-params_encoded_view[params_encoded_view]>
parse_query(string_view s) noexcept;
----

== Description

pass:v,q[This function parses the string and returns the] pass:v,q[corresponding params object if the string is valid,]
pass:v,q[otherwise returns an error.]

=== BNF
[,cpp]
----
----

=== Exception Safety
pass:v,q[No-throw guarantee.]

=== Specification



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base]

= Class url_base

pass:v,q[Common functionality for containers]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L63[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class url_base
    : public xref:boost-urls-url_view_base[url_view_base];
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-authority[`pass:v[authority]`] |
pass:v,q[Return the authority]

|xref:boost-urls-url_view_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the url string]

|xref:boost-urls-url_base-c_str[`pass:v[c_str]`] |
pass:v,q[Return the url as a null-terminated string]

|xref:boost-urls-url_base-capacity[`pass:v[capacity]`] |
pass:v,q[Return the number of characters that can be stored without reallocating]

|xref:boost-urls-url_base-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents while preserving the capacity]

|xref:boost-urls-url_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing this with another url]

|xref:boost-urls-url_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the url's character buffer]

|xref:boost-urls-url_view_base-digest[`pass:v[digest]`] |

|xref:boost-urls-url_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the url is empty]

|xref:boost-urls-url_view_base-encoded_authority[`pass:v[encoded_authority]`] |
pass:v,q[Return the authority.]

|xref:boost-urls-url_view_base-encoded_fragment[`pass:v[encoded_fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-encoded_host[`pass:v[encoded_host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_address[`pass:v[encoded_host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_and_port[`pass:v[encoded_host_and_port]`] |
pass:v,q[Return the host and port]

|xref:boost-urls-url_view_base-encoded_host_name[`pass:v[encoded_host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-encoded_origin[`pass:v[encoded_origin]`] |
pass:v,q[Return the origin]

|xref:boost-urls-url_view_base-encoded_params[`pass:v[encoded_params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-encoded_password[`pass:v[encoded_password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-encoded_path[`pass:v[encoded_path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-encoded_query[`pass:v[encoded_query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-encoded_resource[`pass:v[encoded_resource]`] |
pass:v,q[Return the resource]

|xref:boost-urls-url_view_base-encoded_segments[`pass:v[encoded_segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-encoded_target[`pass:v[encoded_target]`] |
pass:v,q[Return the target]

|xref:boost-urls-url_view_base-encoded_user[`pass:v[encoded_user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-encoded_userinfo[`pass:v[encoded_userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-encoded_zone_id[`pass:v[encoded_zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url_view_base-fragment[`pass:v[fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-has_authority[`pass:v[has_authority]`] |
pass:v,q[Return true if an authority is present]

|xref:boost-urls-url_view_base-has_fragment[`pass:v[has_fragment]`] |
pass:v,q[Return true if a fragment is present]

|xref:boost-urls-url_view_base-has_password[`pass:v[has_password]`] |
pass:v,q[Return true if a password is present]

|xref:boost-urls-url_view_base-has_port[`pass:v[has_port]`] |
pass:v,q[Return true if a port is present]

|xref:boost-urls-url_view_base-has_query[`pass:v[has_query]`] |
pass:v,q[Return true if a query is present]

|xref:boost-urls-url_view_base-has_scheme[`pass:v[has_scheme]`] |
pass:v,q[Return true a scheme is present]

|xref:boost-urls-url_view_base-has_userinfo[`pass:v[has_userinfo]`] |
pass:v,q[Return true if a userinfo is present]

|xref:boost-urls-url_view_base-host[`pass:v[host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_address[`pass:v[host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_ipv4_address[`pass:v[host_ipv4_address]`] |
pass:v,q[Return the host IPv4 address]

|xref:boost-urls-url_view_base-host_ipv6_address[`pass:v[host_ipv6_address]`] |
pass:v,q[Return the host IPv6 address]

|xref:boost-urls-url_view_base-host_ipvfuture[`pass:v[host_ipvfuture]`] |
pass:v,q[Return the host IPvFuture address]

|xref:boost-urls-url_view_base-host_name[`pass:v[host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-host_type[`pass:v[host_type]`] |
pass:v,q[Return the host type]

|xref:boost-urls-url_view_base-is_path_absolute[`pass:v[is_path_absolute]`] |
pass:v,q[Return true if the path is absolute]

|xref:boost-urls-url_base-normalize[`pass:v[normalize]`] |
pass:v,q[Normalize the URL components]

|xref:boost-urls-url_base-normalize_authority[`pass:v[normalize_authority]`] |
pass:v,q[Normalize the URL authority]

|xref:boost-urls-url_base-normalize_fragment[`pass:v[normalize_fragment]`] |
pass:v,q[Normalize the URL fragment]

|xref:boost-urls-url_base-normalize_path[`pass:v[normalize_path]`] |
pass:v,q[Normalize the URL path]

|xref:boost-urls-url_base-normalize_query[`pass:v[normalize_query]`] |
pass:v,q[Normalize the URL query]

|xref:boost-urls-url_base-normalize_scheme[`pass:v[normalize_scheme]`] |
pass:v,q[Normalize the URL scheme]

|xref:boost-urls-url_view_base-2conversion[`pass:v[operator string_view]`] |
pass:v,q[Return the URL as a core::string_view]

|xref:boost-urls-url_view_base-params[`pass:v[params]`] |
pass:v,q[Return the query as a container of parameters]

xref:boost-urls-url_view_base-params-05[url_view_base::params]

|xref:boost-urls-url_view_base-password[`pass:v[password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-path[`pass:v[path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-persist[`pass:v[persist]`] |
pass:v,q[Return a shared, persistent copy of the url]

|xref:boost-urls-url_view_base-port[`pass:v[port]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-port_number[`pass:v[port_number]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-query[`pass:v[query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_base-remove_authority[`pass:v[remove_authority]`] |
pass:v,q[Remove the authority]

|xref:boost-urls-url_base-remove_fragment[`pass:v[remove_fragment]`] |
pass:v,q[Remove the fragment]

|xref:boost-urls-url_base-remove_origin[`pass:v[remove_origin]`] |
pass:v,q[Remove the origin component]

|xref:boost-urls-url_base-remove_password[`pass:v[remove_password]`] |
pass:v,q[Remove the password]

|xref:boost-urls-url_base-remove_port[`pass:v[remove_port]`] |
pass:v,q[Remove the port]

|xref:boost-urls-url_base-remove_query[`pass:v[remove_query]`] |
pass:v,q[Remove the query]

|xref:boost-urls-url_base-remove_scheme[`pass:v[remove_scheme]`] |
pass:v,q[Remove the scheme]

|xref:boost-urls-url_base-remove_userinfo[`pass:v[remove_userinfo]`] |
pass:v,q[Remove the userinfo]

|xref:boost-urls-url_base-reserve[`pass:v[reserve]`] |
pass:v,q[Adjust the capacity without changing the size]

|xref:boost-urls-url_base-resolve[`pass:v[resolve]`] |
pass:v,q[Resolve a URL reference against this base URL]

|xref:boost-urls-url_view_base-scheme[`pass:v[scheme]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-scheme_id[`pass:v[scheme_id]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-segments[`pass:v[segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_base-set_encoded_authority[`pass:v[set_encoded_authority]`] |
pass:v,q[Set the authority]

|xref:boost-urls-url_base-set_encoded_fragment[`pass:v[set_encoded_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_encoded_host[`pass:v[set_encoded_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_encoded_host_address[`pass:v[set_encoded_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_encoded_host_name[`pass:v[set_encoded_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_encoded_params[`pass:v[set_encoded_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_encoded_password[`pass:v[set_encoded_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_encoded_path[`pass:v[set_encoded_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_encoded_query[`pass:v[set_encoded_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_encoded_user[`pass:v[set_encoded_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_encoded_userinfo[`pass:v[set_encoded_userinfo]`] |
pass:v,q[Set the userinfo.]

|xref:boost-urls-url_base-set_fragment[`pass:v[set_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_host[`pass:v[set_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_host_address[`pass:v[set_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv4[`pass:v[set_host_ipv4]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv6[`pass:v[set_host_ipv6]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipvfuture[`pass:v[set_host_ipvfuture]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_name[`pass:v[set_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_params[`pass:v[set_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_password[`pass:v[set_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_path[`pass:v[set_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_path_absolute[`pass:v[set_path_absolute]`] |
pass:v,q[Set if the path is absolute]

|xref:boost-urls-url_base-set_port[`pass:v[set_port]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_port_number[`pass:v[set_port_number]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_query[`pass:v[set_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_scheme[`pass:v[set_scheme]`] |
pass:v,q[Set the scheme]

|xref:boost-urls-url_base-set_scheme_id[`pass:v[set_scheme_id]`] |

|xref:boost-urls-url_base-set_user[`pass:v[set_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_userinfo[`pass:v[set_userinfo]`] |
pass:v,q[Set the userinfo]

|xref:boost-urls-url_view_base-size[`pass:v[size]`] |
pass:v,q[Return the number of characters in the url]

|xref:boost-urls-url_view_base-user[`pass:v[user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-userinfo[`pass:v[userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-zone_id[`pass:v[zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-8friend-02[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-05[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-03[`pass:v[operator<<]`] |

|xref:boost-urls-url_view_base-8friend-04[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-07c[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-073[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-06[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_base-8friend[`pass:v[resolve]`] |

|===

== Description

pass:v,q[This base class is used by the library] pass:v,q[to provide common member functions for]
pass:v,q[containers. This cannot be instantiated]
pass:v,q[directly; Instead, use one of the]
pass:v,q[containers or functions:]

=== Containers

* xref:boost-urls-url[url]

* xref:boost-urls-url_view[url_view]

* xref:boost-urls-static_url[static_url]

=== Functions

* xref:boost-urls-parse_absolute_uri[parse_absolute_uri]

* xref:boost-urls-parse_origin_form[parse_origin_form]

* xref:boost-urls-parse_relative_ref[parse_relative_ref]

* xref:boost-urls-parse_uri[parse_uri]

* xref:boost-urls-parse_uri_reference[parse_uri_reference]




[#boost-urls-url_base-c_str]

= Function url_base::c_str

pass:v,q[Return the url as a null-terminated string]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L128[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
c_str() const noexcept;
----

== Description

pass:v,q[This function returns a pointer to a null] pass:v,q[terminated string representing the url,]
pass:v,q[which may contain percent escapes.]

=== Example
[,cpp]
----
assert( std::strlen( url( "http://www.example.com" ).c_str() ) == 22 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-url_base-capacity]

= Function url_base::capacity

pass:v,q[Return the number of characters that can be stored without reallocating]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L145[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
capacity() const noexcept;
----

== Description

pass:v,q[This does not include the null terminator,] pass:v,q[which is always present.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-url_base-clear]

= Function url_base::clear

pass:v,q[Clear the contents while preserving the capacity]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L164[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
clear() noexcept;
----

== Description


=== Postconditions
[,cpp]
----
this->empty() == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[No-throw guarantee.]



== Return Value

* `void` 





[#boost-urls-url_base-reserve]

= Function url_base::reserve

pass:v,q[Adjust the capacity without changing the size]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L186[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
reserve(size_t n);
----

== Description

pass:v,q[This function adjusts the capacity] pass:v,q[of the container in characters, without]
pass:v,q[affecting the current contents. Has]
pass:v,q[no effect if `n]
pass:v,q[<]
pass:v,q[= this->capacity()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *n*
| `size_t`

|===




[#boost-urls-url_base-set_scheme]

= Function url_base::set_scheme

pass:v,q[Set the scheme]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L242[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_scheme(string_view s);
----

== Description

pass:v,q[The scheme is set to the specified] pass:v,q[string, which must contain a valid]
pass:v,q[scheme without any trailing colon]
pass:v,q[(':').]
pass:v,q[Note that schemes are case-insensitive,]
pass:v,q[and the canonical form is lowercased.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_scheme( "https" ).scheme_id() == scheme::https );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
scheme        = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[            3.1. Scheme (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_scheme_id]

= Function url_base::set_scheme_id



== Synopsis

Declared in header `</boost/url/url_base.hpp#L276[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_scheme_id(xref:boost-urls-scheme[scheme] id);
----


[#boost-urls-url_base-remove_scheme]

= Function url_base::remove_scheme

pass:v,q[Remove the scheme]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L316[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_scheme();
----

== Description

pass:v,q[This function removes the scheme if it] pass:v,q[is present.]

=== Example
[,cpp]
----
assert( url("http://www.example.com/index.htm" ).remove_scheme().buffer() == "//www.example.com/index.htm" );
----

=== Postconditions
[,cpp]
----
this->has_scheme() == false && this->scheme_id() == scheme::none
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

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

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[            3.1. Scheme (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-set_encoded_authority]

= Function url_base::set_encoded_authority

pass:v,q[Set the authority]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L361[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_authority(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the authority] pass:v,q[to the specified string.] pass:v,q[The string may contain percent-escapes.]

=== Example
[,cpp]
----
assert( url().set_encoded_authority( "My%20Computer" ).has_authority() );
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = *( unreserved / pct-encoded / sub-delims / ":" )
host          = IP-literal / IPv4address / reg-name
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[            3.2. Authority (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-remove_authority]

= Function url_base::remove_authority

pass:v,q[Remove the authority]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L403[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_authority();
----

== Description

pass:v,q[This function removes the authority,] pass:v,q[which includes the userinfo, host, and]
pass:v,q[a port if present.]

=== Example
[,cpp]
----
assert( url( "http://example.com/echo.cgi" ).remove_authority().buffer() == "http:/echo.cgi" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == false && this->has_userinfo() == false && this->has_port() == false
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = *( unreserved / pct-encoded / sub-delims / ":" )
host          = IP-literal / IPv4address / reg-name
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[            3.2. Authority (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-set_userinfo]

= Function url_base::set_userinfo

pass:v,q[Set the userinfo]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L469[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_userinfo(string_view s);
----

== Description

pass:v,q[The userinfo is set to the given string,] pass:v,q[which may contain percent-escapes.]
pass:v,q[Any special or reserved characters in the]
pass:v,q[string are automatically percent-encoded.]
pass:v,q[The effects on the user and password]
pass:v,q[depend on the presence of a colon (':')]
pass:v,q[in the string:]

* pass:v,q[If an unescaped colon exists, the]
pass:v,q[characters up to the colon become]
pass:v,q[the user and the rest of the characters]
pass:v,q[after the colon become the password.]
pass:v,q[In this case]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns]
pass:v,q[true. Otherwise,]

* pass:v,q[If there is no colon, the user is]
pass:v,q[set to the string. The function]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns false.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_userinfo( "user:pass" ).encoded_user() == "user" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_userinfo]

= Function url_base::set_encoded_userinfo

pass:v,q[Set the userinfo.]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L535[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_userinfo(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[The userinfo is set to the given string,] pass:v,q[which may contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The effects on the user and password]
pass:v,q[depend on the presence of a colon (':')]
pass:v,q[in the string:]

* pass:v,q[If an unescaped colon exists, the]
pass:v,q[characters up to the colon become]
pass:v,q[the user and the rest of the characters]
pass:v,q[after the colon become the password.]
pass:v,q[In this case]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns]
pass:v,q[true. Otherwise,]

* pass:v,q[If there is no colon, the user is]
pass:v,q[set to the string. The function]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns false.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_userinfo( "john%20doe" ).user() == "john doe" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-remove_userinfo]

= Function url_base::remove_userinfo

pass:v,q[Remove the userinfo]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L576[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_userinfo() noexcept;
----

== Description

pass:v,q[This function removes the userinfo if] pass:v,q[present, without removing any authority.]

=== Example
[,cpp]
----
assert( url( "http://user@example.com" ).remove_userinfo().has_userinfo() == false );
----

=== Postconditions
[,cpp]
----
this->has_userinfo() == false && this->encoded_userinfo().empty == true
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-set_user]

= Function url_base::set_user

pass:v,q[Set the user]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L625[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_user(string_view s);
----

== Description

pass:v,q[This function sets the user part of the] pass:v,q[userinfo to the string.]
pass:v,q[Any special or reserved characters in the]
pass:v,q[string are automatically percent-encoded.]

=== Example
[,cpp]
----
assert( url().set_user("john doe").encoded_userinfo() == "john%20doe" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_userinfo() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_user]

= Function url_base::set_encoded_user

pass:v,q[Set the user]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L678[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_user(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the user part of the] pass:v,q[userinfo the the string, which may]
pass:v,q[contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url().set_encoded_user("john%20doe").userinfo() == "john doe" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_userinfo() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-set_password]

= Function url_base::set_password

pass:v,q[Set the password.]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L730[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_password(string_view s);
----

== Description

pass:v,q[This function sets the password in] pass:v,q[the userinfo to the string.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url("http://user@example.com").set_password( "pass" ).encoded_userinfo() == "user:pass" );
----

=== Postconditions
[,cpp]
----
this->has_password() == true && this->password() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_password]

= Function url_base::set_encoded_password

pass:v,q[Set the password.]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L787[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_password(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the password in] pass:v,q[the userinfo to the string, which]
pass:v,q[may contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url("http://user@example.com").set_encoded_password( "pass" ).encoded_userinfo() == "user:pass" );
----

=== Postconditions
[,cpp]
----
this->has_password() == true
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-remove_password]

= Function url_base::remove_password

pass:v,q[Remove the password]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L838[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_password() noexcept;
----

== Description

pass:v,q[This function removes the password from] pass:v,q[the userinfo if a password exists. If]
pass:v,q[there is no userinfo or no authority,]
pass:v,q[the call has no effect.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://user:pass@example.com" ).remove_password().authority().buffer() == "user@example.com" );
----

=== Postconditions
[,cpp]
----
this->has_password() == false && this->encoded_password().empty() == true
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-set_host]

= Function url_base::set_host

pass:v,q[Set the host]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L921[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_host(string_view s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address]
pass:v,q[enclosed in square brackets, then the]
pass:v,q[host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture]
pass:v,q[address enclosed in square brackets, then]
pass:v,q[the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_host]

= Function url_base::set_encoded_host

pass:v,q[Set the host]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1005[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_host(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address]
pass:v,q[enclosed in square brackets, then the]
pass:v,q[host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture]
pass:v,q[address enclosed in square brackets, then]
pass:v,q[the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string. This string can contain percent]
pass:v,q[escapes, or can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-set_host_address]

= Function url_base::set_host_address

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1103[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_host_address(string_view s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host_address( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255

IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal

IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_host_address]

= Function url_base::set_encoded_host_address

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1206[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_host_address(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string. This string can contain percent]
pass:v,q[escapes, or can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255

IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal

IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-set_host_ipv4]

= Function url_base::set_host_ipv4

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1262[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_host_ipv4(const xref:boost-urls-ipv4_address[ipv4_address]& addr);
----

== Description

pass:v,q[The host is set to the specified IPv4] pass:v,q[address.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

=== Example
[,cpp]
----
assert( url("http://www.example.com").set_host_ipv4( ipv4_address( "127.0.0.1" ) ).buffer() == "http://127.0.0.1" );
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv4_address() == addr && this->host_type() == host_type::ipv4
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *addr*
| ``

|===




[#boost-urls-url_base-set_host_ipv6]

= Function url_base::set_host_ipv6

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1326[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_host_ipv6(const xref:boost-urls-ipv6_address[ipv6_address]& addr);
----

== Description

pass:v,q[The host is set to the specified IPv6] pass:v,q[address.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

=== Example
[,cpp]
----
assert( url().set_host_ipv6( ipv6_address( "1::6:c0a8:1" ) ).authority().buffer() == "[1::6:c0a8:1]" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::ipv6
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *addr*
| ``

|===




[#boost-urls-url_base-set_host_ipvfuture]

= Function url_base::set_host_ipvfuture

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1378[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_host_ipvfuture(string_view s);
----

== Description

pass:v,q[The host is set to the specified IPvFuture] pass:v,q[string.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

=== Example
[,cpp]
----
assert( url().set_host_ipvfuture( "v42.bis" ).buffer() == "//[v42.bis]" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipvfuture) == s && this->host_type() == host_type::ipvfuture
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_host_name]

= Function url_base::set_host_name

pass:v,q[Set the host to a name]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1425[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_host_name(string_view s);
----

== Description

pass:v,q[The host is set to the specified string,] pass:v,q[which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm").set_host_name( "localhost" ).host_address() == "localhost" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::name
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_host_name]

= Function url_base::set_encoded_host_name

pass:v,q[Set the host to a name]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1478[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_host_name(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[The host is set to the specified string,] pass:v,q[which may contain percent-escapes and]
pass:v,q[can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm").set_encoded_host_name( "localhost" ).host_address() == "localhost" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::name
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-set_port_number]

= Function url_base::set_port_number

pass:v,q[Set the port]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1522[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_port_number(uint16_t n);
----

== Description

pass:v,q[The port is set to the specified integer.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_port_number( 8080 ).authority().buffer() == "www.example.com:8080" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_port() == true && this->port_number() == n
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *n*
| `uint16_t`

|===




[#boost-urls-url_base-set_port]

= Function url_base::set_port

pass:v,q[Set the port]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1565[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_port(string_view s);
----

== Description

pass:v,q[This port is set to the string, which] pass:v,q[must contain only digits or be empty.]
pass:v,q[An empty port string is distinct from]
pass:v,q[having no port.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_port( "8080" ).authority().buffer() == "www.example.com:8080" );
----

=== Postconditions
[,cpp]
----
this->has_port() == true && this->port_number() == n && this->port() == std::to_string(n)
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-remove_port]

= Function url_base::remove_port

pass:v,q[Remove the port]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1603[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_port() noexcept;
----

== Description

pass:v,q[If a port exists, it is removed. The rest] pass:v,q[of the authority is unchanged.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com:80" ).remove_port().authority().buffer() == "www.example.com" );
----

=== Postconditions
[,cpp]
----
this->has_port() == false && this->port_number() == 0 && this->port() == ""
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-set_path_absolute]

= Function url_base::set_path_absolute

pass:v,q[Set if the path is absolute]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1665[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
set_path_absolute(bool absolute);
----

== Description

pass:v,q[This function adjusts the path to make] pass:v,q[it absolute or not, depending on the]
pass:v,q[parameter.]
[NOTE]
pass:v,q[If an authority is present, the path]
pass:v,q[is always absolute. In this case, the]
pass:v,q[function has no effect.]

=== Example
[,cpp]
----
url u( "path/to/file.txt" );
assert( u.set_path_absolute( true ) );
assert( u.buffer() == "/path/to/file.txt" );
----

=== Postconditions
[,cpp]
----
this->is_path_absolute() == true && this->encoded_path().front() == '/'
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *absolute*
| `bool`

|===




[#boost-urls-url_base-set_path]

= Function url_base::set_path

pass:v,q[Set the path.]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1731[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_path(string_view s);
----

== Description

pass:v,q[This function sets the path to the] pass:v,q[string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
[NOTE]
pass:v,q[The library may adjust the final result]
pass:v,q[to ensure that no other parts of the url]
pass:v,q[is semantically affected.]
[NOTE]
pass:v,q[This function does not encode '/' chars, which]
pass:v,q[are unreserved for paths but reserved for]
pass:v,q[path segments. If a path segment should include]
pass:v,q[encoded '/'s to differentiate it from path separators,]
pass:v,q[the functions]
xref:boost-urls-url_base-set_encoded_path[set_encoded_path]
pass:v,q[or]
xref:boost-urls-url_base-segments-04[segments]
pass:v,q[should be used instead.]

=== Example
[,cpp]
----
url u( "http://www.example.com" );

u.set_path( "path/to/file.txt" );

assert( u.path() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_path]

= Function url_base::set_encoded_path

pass:v,q[Set the path.]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1796[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_path(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the path to the] pass:v,q[string, which may contain percent-escapes]
pass:v,q[and can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
[NOTE]
pass:v,q[The library may adjust the final result]
pass:v,q[to ensure that no other parts of the url]
pass:v,q[is semantically affected.]

=== Example
[,cpp]
----
url u( "http://www.example.com" );

u.set_encoded_path( "path/to/file.txt" );

assert( u.encoded_path() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-segments]

= Overload set url_base::segments

== Members


pass:v,q[Return the path as a container of segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]
segments() noexcept;
  xref:boost-urls-url_base-segments-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the path as a container of segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_view[segments_view]
segments() const noexcept;
  xref:boost-urls-url_base-segments-04[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url_base-encoded_segments]

= Overload set url_base::encoded_segments

== Members


pass:v,q[Return the path as a container of segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]
encoded_segments() noexcept;
  xref:boost-urls-url_base-encoded_segments-0e8[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the path as a container of segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_view[segments_encoded_view]
encoded_segments() const noexcept;
  xref:boost-urls-url_base-encoded_segments-0e5[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url_base-set_query]

= Function url_base::set_query

pass:v,q[Set the query]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1973[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_query(string_view s);
----

== Description

pass:v,q[This sets the query to the string, which] pass:v,q[can be empty.] pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_query( "id=42" ).query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true && this->query() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_query]

= Function url_base::set_encoded_query

pass:v,q[Set the query]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2028[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_query(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This sets the query to the string, which] pass:v,q[may contain percent-escapes and can be]
pass:v,q[empty.]
pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_query( "id=42" ).encoded_query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true && this->query() == decode_view( s );
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-params]

= Overload set url_base::params

== Members


pass:v,q[Return the query as a container of parameters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]
params() noexcept;
  xref:boost-urls-url_base-params-03[pass:c,q,m[*_» more..._*]]
----


xref:boost-urls-url_view_base-params-05[url_view_base::params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_view[params_view]
params() const noexcept;
  xref:boost-urls-url_base-params-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the query as a container of parameters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]
params(xref:boost-urls-encoding_opts[encoding_opts] opt) noexcept;
  xref:boost-urls-url_base-params-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url_base-encoded_params]

= Overload set url_base::encoded_params

== Members


pass:v,q[Return the query as a container of parameters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_view[params_encoded_view]
encoded_params() const noexcept;
  xref:boost-urls-url_base-encoded_params-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Return the query as a container of parameters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_ref[params_encoded_ref]
encoded_params() noexcept;
  xref:boost-urls-url_base-encoded_params-06[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url_base-set_params]

= Function url_base::set_params

pass:v,q[Set the query params]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2243[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_params(initializer_list<xref:boost-urls-param_view[param_view]> ps) noexcept;
----

== Description

pass:v,q[This sets the query params to the list] pass:v,q[of param_view, which can be empty.]
pass:v,q[An empty list of params is distinct from]
pass:v,q[having no params.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_params( {"id", "42"} ).query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Complexity
pass:v,q[Linear.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *ps*
| `initializer_list`

|===




[#boost-urls-url_base-set_encoded_params]

= Function url_base::set_encoded_params

pass:v,q[Set the query params]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2303[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_params(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> ps) noexcept;
----

== Description

pass:v,q[This sets the query params to the elements] pass:v,q[in the list, which may contain]
pass:v,q[percent-escapes and can be empty.]
pass:v,q[An empty list of params is distinct from]
pass:v,q[having no query.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_params( {"id", "42"} ).encoded_query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true
----

=== Complexity
pass:v,q[Linear.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *ps*
| `initializer_list`

|===




[#boost-urls-url_base-remove_query]

= Function url_base::remove_query

pass:v,q[Remove the query]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2345[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_query() noexcept;
----

== Description

pass:v,q[If a query is present, it is removed.] pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com?id=42" ).remove_query().buffer() == "http://www.example.com" );
----

=== Postconditions
[,cpp]
----
this->has_query() == false && this->params().empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 





[#boost-urls-url_base-remove_fragment]

= Function url_base::remove_fragment

pass:v,q[Remove the fragment]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2390[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_fragment() noexcept;
----

== Description

pass:v,q[This function removes the fragment.] pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]

=== Example
[,cpp]
----
assert( url( "?first=john&last=doe#anchor" ).remove_fragment().buffer() == "?first=john&last=doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == false && this->encoded_fragment() == ""
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 





[#boost-urls-url_base-set_fragment]

= Function url_base::set_fragment

pass:v,q[Set the fragment.]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2434[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_fragment(string_view s);
----

== Description

pass:v,q[This function sets the fragment to the] pass:v,q[specified string, which may be empty.]
pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url("?first=john&last=doe" ).set_encoded_fragment( "john doe" ).encoded_fragment() == "john%20doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == true && this->fragment() == s
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-set_encoded_fragment]

= Function url_base::set_encoded_fragment

pass:v,q[Set the fragment.]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2485[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
set_encoded_fragment(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the fragment to the] pass:v,q[specified string, which may contain]
pass:v,q[percent-escapes and which may be empty.]
pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url("?first=john&last=doe" ).set_encoded_fragment( "john%2Ddoe" ).fragment() == "john-doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == true && this->fragment() == decode_view( s )
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url_base-remove_origin]

= Function url_base::remove_origin

pass:v,q[Remove the origin component]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2516[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
remove_origin();
----

== Description

pass:v,q[This function removes the origin, which] pass:v,q[consists of the scheme and authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm" ).remove_origin().buffer() == "/index.htm" );
----

=== Postconditions
[,cpp]
----
this->scheme_id() == scheme::none && this->has_authority() == false
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-url_base-normalize]

= Function url_base::normalize

pass:v,q[Normalize the URL components]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2539[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
normalize();
----

== Description

pass:v,q[Applies Syntax-based normalization to] pass:v,q[all components of the URL.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-normalize_scheme]

= Function url_base::normalize_scheme

pass:v,q[Normalize the URL scheme]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2558[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
normalize_scheme();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL scheme.]
pass:v,q[The scheme is normalized to lowercase.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-normalize_authority]

= Function url_base::normalize_authority

pass:v,q[Normalize the URL authority]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2580[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
normalize_authority();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL authority.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-normalize_path]

= Function url_base::normalize_path

pass:v,q[Normalize the URL path]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2603[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
normalize_path();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL path.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded. Redundant]
pass:v,q[path-segments are removed.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-normalize_query]

= Function url_base::normalize_query

pass:v,q[Normalize the URL query]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2625[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
normalize_query();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL query.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-normalize_fragment]

= Function url_base::normalize_fragment

pass:v,q[Normalize the URL fragment]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2647[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
normalize_fragment();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL fragment.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url_base-resolve]

= Function url_base::resolve

pass:v,q[Resolve a URL reference against this base URL]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2740[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<void>
resolve(const xref:boost-urls-url_view_base[url_view_base]& ref);
----

== Description

pass:v,q[This function attempts to resolve a URL] pass:v,q[reference `ref` against this base URL]
pass:v,q[in a manner similar to that of a web browser]
pass:v,q[resolving an anchor tag.]
pass:v,q[This URL must satisfy the]
pass:v,q[URI]
pass:v,q[grammar. In other words, it must contain]
pass:v,q[a scheme.]
pass:v,q[Relative references are only usable when]
pass:v,q[in the context of a base absolute URI.]
pass:v,q[This process of resolving a relative]
pass:v,q[reference]
pass:v,q[within the context of]
pass:v,q[a]
pass:v,q[base]
pass:v,q[URI is defined in detail]
pass:v,q[in rfc3986 (see below).]
pass:v,q[The resolution process works as if the]
pass:v,q[relative reference is appended to the base]
pass:v,q[URI and the result is normalized.]
pass:v,q[Given the input base URL, this function]
pass:v,q[resolves the relative reference]
pass:v,q[as if performing the following steps:]

* pass:v,q[Ensure the base URI has at least a scheme]

* pass:v,q[Normalizing the reference path]

* pass:v,q[Merge base and reference paths]

* pass:v,q[Normalize the merged path]
pass:v,q[This function places the result of the]
pass:v,q[resolution into this URL in place.]
pass:v,q[If an error occurs, the contents of]
pass:v,q[this URL are unspecified and a]
pass:v,q[result]
pass:v,q[with an `system::error_code` is returned.]

=== Example
[,cpp]
----
url base1( "/one/two/three" );
base1.resolve("four");
assert( base1.buffer() == "/one/two/four" );

url base2( "http://example.com/" )
base2.resolve("/one");
assert( base2.buffer() == "http://example.com/one" );

url base3( "http://example.com/one" );
base3.resolve("/two");
assert( base3.buffer() == "http://example.com/two" );

url base4( "http://a/b/c/d;p?q" );
base4.resolve("g#s");
assert( base4.buffer() == "http://a/b/c/g#s" );
----

=== BNF
[,cpp]
----
absolute-URI  = scheme ":" hier-part [ "?" query ]
----

=== Exception Safety
pass:v,q[Basic guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification
link:https://datatracker.ietf.org/doc/html/rfc3986#section-5[5. Reference Resolution (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *ref*
| ``

|===




[#boost-urls-url_base-8friend]

= Friend resolve



== Synopsis

Declared in header `</boost/url/url_base.hpp#L2744[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
result<void>
resolve(
    const xref:boost-urls-url_view_base[url_view_base]& base,
    const xref:boost-urls-url_view_base[url_view_base]& ref,
    xref:boost-urls-url_base[url_base]& dest);
----


[#boost-urls-url_base-op_t]

= Class url_base::op_t



== Synopsis

Declared in header `</boost/url/url_base.hpp#L78[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct op_t;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_base-op_t-move[`pass:v[move]`] |

|xref:boost-urls-url_base-op_t-2constructor[`pass:v[op_t]`] |

|xref:boost-urls-url_base-op_t-2destructor[`pass:v[~op_t]`] |

|===



[#boost-urls-url_base-op_t-2destructor]

= Function url_base::op_t::~op_t



== Synopsis

Declared in header `</src/url_base.cpp#L55[src/url_base.cpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
~op_t();
----


[#boost-urls-url_base-op_t-2constructor]

= Function url_base::op_t::op_t



== Synopsis

Declared in header `</src/url_base.cpp#L64[src/url_base.cpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
op_t(
    xref:boost-urls-url_base[url_base]& impl_,
    string_view* s0_ = nullptr,
    string_view* s1_ = nullptr) noexcept;
----


[#boost-urls-url_base-op_t-move]

= Function url_base::op_t::move



== Synopsis

Declared in header `</src/url_base.cpp#L77[src/url_base.cpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
move(
    char* dest,
    const char* src,
    size_t n) noexcept;
----


[#boost-urls-params_encoded_ref]

= Class params_encoded_ref

pass:v,q[A view representing query parameters in a URL]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L73[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class params_encoded_ref
    : public xref:boost-urls-params_encoded_base[params_encoded_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-params_encoded_base-iterator[iterator]

|xref:boost-urls-params_encoded_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_encoded_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-params_encoded_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-params_encoded_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-params_encoded_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type to represent sizes.]

|xref:boost-urls-params_encoded_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_ref-append[`pass:v[append]`] |
pass:v,q[Append params]

|xref:boost-urls-params_encoded_ref-assign[`pass:v[assign]`] |
pass:v,q[Assign params]

|xref:boost-urls-params_encoded_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-params_encoded_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the query corresponding to these params]

|xref:boost-urls-params_encoded_ref-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents of the container]

|xref:boost-urls-params_encoded_base-contains[`pass:v[contains]`] |
pass:v,q[Return true if a matching key exists]

|xref:boost-urls-params_encoded_base-count[`pass:v[count]`] |
pass:v,q[Return the number of matching keys]

|xref:boost-urls-params_encoded_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no params]

|xref:boost-urls-params_encoded_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-params_encoded_ref-erase[`pass:v[erase]`] |
pass:v,q[Erase params]

|xref:boost-urls-params_encoded_base-find[`pass:v[find]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_encoded_base-find_last[`pass:v[find_last]`] |
pass:v,q[Find a matching key]

|xref:boost-urls-params_encoded_ref-insert[`pass:v[insert]`] |
pass:v,q[Insert params]

|xref:boost-urls-params_encoded_ref-2conversion[`pass:v[operator params_encoded_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-params_encoded_ref-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-params_encoded_ref-2constructor[`pass:v[params_encoded_ref]`] |
pass:v,q[Constructor]

|xref:boost-urls-params_encoded_ref-replace[`pass:v[replace]`] |
pass:v,q[Replace params]

|xref:boost-urls-params_encoded_ref-set[`pass:v[set]`] |
pass:v,q[Set a value]

|xref:boost-urls-params_encoded_base-size[`pass:v[size]`] |
pass:v,q[Return the number of params]

|xref:boost-urls-params_encoded_ref-unset[`pass:v[unset]`] |
pass:v,q[Remove the value on an element]

|xref:boost-urls-params_encoded_ref-url[`pass:v[url]`] |
pass:v,q[Return the referenced url]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-params_encoded_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the query parameters as a bidirectional view]
pass:v,q[of key value pairs.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[url. The caller is responsible for ensuring]
pass:v,q[that the lifetime of the referenced url]
pass:v,q[extends until it is no longer referenced.]
pass:v,q[The view is modifiable; calling non-const]
pass:v,q[members causes changes to the referenced]
pass:v,q[url.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

params_encoded_ref p = u.encoded_params();
----
pass:v,q[Strings produced when elements are returned]
pass:v,q[have type]
xref:boost-urls-param_pct_view[param_pct_view]
pass:v,q[and represent]
pass:v,q[encoded strings. Strings passed to member]
pass:v,q[functions may contain percent escapes, and]
pass:v,q[throw exceptions on invalid inputs.]

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]
pass:v,q[Modifications made through the container]
pass:v,q[invalidate some iterators to the underlying]
pass:v,q[character buffer:]

* xref:boost-urls-params_encoded_ref-append-07[append]
pass:v,q[: Only `end()`.]

* xref:boost-urls-params_encoded_ref-assign-00[assign,]
xref:boost-urls-params_encoded_ref-clear[clear,]
pass:v,q[`operator=` : All params.]

* xref:boost-urls-params_encoded_ref-erase-08[erase]
pass:v,q[: Erased params and all]
pass:v,q[params after (including `end()`).]

* xref:boost-urls-params_encoded_ref-insert-03[insert]
pass:v,q[: All params at or after]
pass:v,q[the insertion point (including `end()`).]

* xref:boost-urls-params_encoded_ref-replace-0f[replace,]
xref:boost-urls-params_encoded_ref-set-07[set]
pass:v,q[: Modified]
pass:v,q[params and all params]
pass:v,q[after (including `end()`).]




[#boost-urls-params_encoded_ref-2constructor]

= Function params_encoded_ref::params_encoded_ref

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L112[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_encoded_ref(const xref:boost-urls-params_encoded_ref[params_encoded_ref]& other) = default;
----

== Description

pass:v,q[After construction, both views] pass:v,q[reference the same url. Ownership is not]
pass:v,q[transferred; the caller is responsible]
pass:v,q[for ensuring the lifetime of the url]
pass:v,q[extends until it is no longer]
pass:v,q[referenced.]

=== Postconditions
[,cpp]
----
&this->url() == &other.url();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-params_encoded_ref-operator_assign]

= Overload set params_encoded_ref::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_ref[params_encoded_ref]&
operator=(const xref:boost-urls-params_encoded_ref[params_encoded_ref]& other);
  xref:boost-urls-params_encoded_ref-operator_assign-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_ref[params_encoded_ref]&
operator=(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
  xref:boost-urls-params_encoded_ref-operator_assign-03[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_ref-2conversion]

= Function params_encoded_ref::operator params_encoded_view

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L191[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-params_encoded_view[params_encoded_view]() const noexcept;
----

== Description


=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `params_encoded_view` 





[#boost-urls-params_encoded_ref-url]

= Function params_encoded_ref::url

pass:v,q[Return the referenced url]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L217[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
url() const noexcept;
----

== Description

pass:v,q[This function returns the url referenced] pass:v,q[by the view.]

=== Example
[,cpp]
----
url u( "?key=value" );

assert( &u.encoded_params().url() == &u );
----

=== Exception Safety
[,cpp]
----
Throws nothing.
----



== Return Value

* `` 





[#boost-urls-params_encoded_ref-clear]

= Function params_encoded_ref::clear

pass:v,q[Clear the contents of the container]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L250[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
clear() noexcept;
----

== Description

pass:v,q[All iterators are invalidated.]

=== Effects
[,cpp]
----
this->url().remove_query();
----

=== Postconditions
[,cpp]
----
this->empty() == true && this->url().has_query() == false
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-params_encoded_ref-assign]

= Overload set params_encoded_ref::assign

== Members


pass:v,q[Assign params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
  xref:boost-urls-params_encoded_ref-assign-00[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assign params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_encoded_ref-assign-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_ref-append]

= Overload set params_encoded_ref::append

== Members


pass:v,q[Append params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
append(const xref:boost-urls-param_pct_view[param_pct_view]& p);
  xref:boost-urls-params_encoded_ref-append-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Append params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
append(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
  xref:boost-urls-params_encoded_ref-append-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Append params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
append(
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_encoded_ref-append-08[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_ref-insert]

= Overload set params_encoded_ref::insert

== Members


pass:v,q[Insert params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] before,
    const xref:boost-urls-param_pct_view[param_pct_view]& p);
  xref:boost-urls-params_encoded_ref-insert-03[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] before,
    initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
  xref:boost-urls-params_encoded_ref-insert-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_encoded_ref-insert-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_ref-erase]

= Overload set params_encoded_ref::erase

== Members


pass:v,q[Erase params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
erase(xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] pos) noexcept;
  xref:boost-urls-params_encoded_ref-erase-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Erase params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
erase(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] first,
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] last) noexcept;
  xref:boost-urls-params_encoded_ref-erase-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Erase params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
erase(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) noexcept;
  xref:boost-urls-params_encoded_ref-erase-00[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_ref-replace]

= Overload set params_encoded_ref::replace

== Members


pass:v,q[Replace params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] pos,
    const xref:boost-urls-param_pct_view[param_pct_view]& p);
  xref:boost-urls-params_encoded_ref-replace-0f[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] from,
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] to,
    initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
  xref:boost-urls-params_encoded_ref-replace-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace params]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] from,
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-params_encoded_ref-replace-06[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-params_encoded_ref-unset]

= Function params_encoded_ref::unset

pass:v,q[Remove the value on an element]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L832[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
unset(xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] pos) noexcept;
----

== Description

pass:v,q[This function removes the value of] pass:v,q[an element at the specified position.]
pass:v,q[After the call returns, `has_value`]
pass:v,q[for the element is false.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

u.encoded_params().unset( u.encoded_params().begin() );

assert( u.encoded_query() == "first&last=Doe" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

|===




[#boost-urls-params_encoded_ref-set]

= Overload set params_encoded_ref::set

== Members


pass:v,q[Set a value]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
set(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] pos,
    xref:boost-urls-pct_string_view[pct_string_view] value);
  xref:boost-urls-params_encoded_ref-set-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Set a value]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
set(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-pct_string_view[pct_string_view] value,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {});
  xref:boost-urls-params_encoded_ref-set-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_ref]

= Class segments_encoded_ref

pass:v,q[A view representing path segments in a URL]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L88[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class segments_encoded_ref
    : public xref:boost-urls-segments_encoded_base[segments_encoded_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-segments_encoded_base-iterator[iterator]

|xref:boost-urls-segments_encoded_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_encoded_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-segments_encoded_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-segments_encoded_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_encoded_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type used to represent size.]

|xref:boost-urls-segments_encoded_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_ref-assign[`pass:v[assign]`] |
pass:v,q[Assign segments]

|xref:boost-urls-segments_encoded_base-back[`pass:v[back]`] |
pass:v,q[Return the last segment]

|xref:boost-urls-segments_encoded_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-segments_encoded_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-segments_encoded_ref-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents of the container]

|xref:boost-urls-segments_encoded_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no segments]

|xref:boost-urls-segments_encoded_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-segments_encoded_ref-erase[`pass:v[erase]`] |
pass:v,q[Erase segments]

|xref:boost-urls-segments_encoded_base-front[`pass:v[front]`] |
pass:v,q[Return the first segment]

|xref:boost-urls-segments_encoded_ref-insert[`pass:v[insert]`] |
pass:v,q[Insert segments]

|xref:boost-urls-segments_encoded_base-is_absolute[`pass:v[is_absolute]`] |
pass:v,q[Returns true if this references an absolute path.]

|xref:boost-urls-segments_encoded_ref-2conversion[`pass:v[operator segments_encoded_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-segments_encoded_ref-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-segments_encoded_ref-pop_back[`pass:v[pop_back]`] |
pass:v,q[Remove the last segment]

|xref:boost-urls-segments_encoded_ref-push_back[`pass:v[push_back]`] |
pass:v,q[Append a segment]

|xref:boost-urls-segments_encoded_ref-replace[`pass:v[replace]`] |
pass:v,q[Replace segments]

|xref:boost-urls-segments_encoded_ref-2constructor[`pass:v[segments_encoded_ref]`] |
pass:v,q[Constructor]

|xref:boost-urls-segments_encoded_base-size[`pass:v[size]`] |
pass:v,q[Return the number of segments]

|xref:boost-urls-segments_encoded_ref-url[`pass:v[url]`] |
pass:v,q[Return the referenced url]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_encoded_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the path as a bidirectional view of segments,]
pass:v,q[where each segment is a string which may]
pass:v,q[contain percent-escapes.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[character buffer. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the buffer]
pass:v,q[extends until it is no longer referenced.]
pass:v,q[The view is modifiable; calling non-const]
pass:v,q[members causes changes to the referenced]
pass:v,q[url.]

=== Example
[,cpp]
----
url u( "/path/to/file.txt" );

segments_encoded_ref ps = u.encoded_segments();
----
pass:v,q[The strings returned when iterators are]
pass:v,q[dereferenced have type]
xref:boost-urls-pct_string_view[pct_string_view]
pass:v,q[and may contain percent-escapes.]
pass:v,q[Reserved characters in inputs are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in inputs are preserved.]
pass:v,q[Exceptions are thrown on invalid inputs.]

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]
pass:v,q[Modifications made through the container]
pass:v,q[invalidate some or all iterators:]

* xref:boost-urls-segments_encoded_ref-push_back[push_back]
pass:v,q[: Only `end()`.]

* xref:boost-urls-segments_encoded_ref-assign-0e[assign,]
xref:boost-urls-segments_encoded_ref-clear[clear,]
xref:boost-urls-segments_encoded_ref-operator_assign-02c[operator=]
pass:v,q[: All elements.]

* xref:boost-urls-segments_encoded_ref-erase-006[erase]
pass:v,q[: Erased elements and all]
pass:v,q[elements after (including `end()`).]

* xref:boost-urls-segments_encoded_ref-insert-04[insert]
pass:v,q[: All elements at or after]
pass:v,q[the insertion point (including `end()`).]

* xref:boost-urls-segments_encoded_ref-replace-07[replace]
pass:v,q[: Modified]
pass:v,q[elements and all elements]
pass:v,q[after (including `end()`).]




[#boost-urls-segments_encoded_ref-2constructor]

= Function segments_encoded_ref::segments_encoded_ref

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L127[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_encoded_ref(const xref:boost-urls-segments_encoded_ref[segments_encoded_ref]& other) = default;
----

== Description

pass:v,q[After construction, both views] pass:v,q[reference the same url. Ownership is not]
pass:v,q[transferred; the caller is responsible]
pass:v,q[for ensuring the lifetime of the url]
pass:v,q[extends until it is no longer]
pass:v,q[referenced.]

=== Postconditions
[,cpp]
----
&this->url() == &other.url();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-segments_encoded_ref-operator_assign]

= Overload set segments_encoded_ref::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]&
operator=(const xref:boost-urls-segments_encoded_ref[segments_encoded_ref]& other);
  xref:boost-urls-segments_encoded_ref-operator_assign-02c[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]&
operator=(const xref:boost-urls-segments_encoded_view[segments_encoded_view]& other);
  xref:boost-urls-segments_encoded_ref-operator_assign-02e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]&
operator=(initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
  xref:boost-urls-segments_encoded_ref-operator_assign-08[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_ref-2conversion]

= Function segments_encoded_ref::operator segments_encoded_view

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L222[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-segments_encoded_view[segments_encoded_view]() const noexcept;
----


[#boost-urls-segments_encoded_ref-url]

= Function segments_encoded_ref::url

pass:v,q[Return the referenced url]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L246[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
url() const noexcept;
----

== Description

pass:v,q[This function returns the url referenced] pass:v,q[by the view.]

=== Example
[,cpp]
----
url u( "/path/to/file.txt" );

assert( &u.encoded_segments().url() == &u );
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-segments_encoded_ref-clear]

= Function segments_encoded_ref::clear

pass:v,q[Clear the contents of the container]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L279[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
clear() noexcept;
----

== Description

pass:v,q[All iterators are invalidated.]

=== Effects
[,cpp]
----
this->url().set_encoded_path( "" );
----

=== Postconditions
[,cpp]
----
this->empty() == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-segments_encoded_ref-assign]

= Overload set segments_encoded_ref::assign

== Members


pass:v,q[Assign segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
  xref:boost-urls-segments_encoded_ref-assign-0e[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assign segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
  xref:boost-urls-segments_encoded_ref-assign-0b[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_ref-insert]

= Overload set segments_encoded_ref::insert

== Members


pass:v,q[Insert segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] before,
    xref:boost-urls-pct_string_view[pct_string_view] s);
  xref:boost-urls-segments_encoded_ref-insert-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] before,
    initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
  xref:boost-urls-segments_encoded_ref-insert-0d[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-segments_encoded_ref-insert-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_ref-erase]

= Overload set segments_encoded_ref::erase

== Members


pass:v,q[Erase segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
erase(xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] pos) noexcept;
  xref:boost-urls-segments_encoded_ref-erase-006[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Erase segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
erase(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] first,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] last) noexcept;
  xref:boost-urls-segments_encoded_ref-erase-00a[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_ref-replace]

= Overload set segments_encoded_ref::replace

== Members


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] pos,
    xref:boost-urls-pct_string_view[pct_string_view] s);
  xref:boost-urls-segments_encoded_ref-replace-07[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] from,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] to,
    xref:boost-urls-pct_string_view[pct_string_view] s);
  xref:boost-urls-segments_encoded_ref-replace-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] from,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] to,
    initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
  xref:boost-urls-segments_encoded_ref-replace-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] from,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-segments_encoded_ref-replace-0f[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_encoded_ref-push_back]

= Function segments_encoded_ref::push_back

pass:v,q[Append a segment]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L751[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
push_back(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function appends a segment to] pass:v,q[the end of the path.] pass:v,q[Reserved characters in the string are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the string are preserved.]
pass:v,q[All end iterators are invalidated.]

=== Postconditions
[,cpp]
----
this->back() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-segments_encoded_ref-pop_back]

= Function segments_encoded_ref::pop_back

pass:v,q[Remove the last segment]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L772[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
pop_back() noexcept;
----

== Description

pass:v,q[This function removes the last segment] pass:v,q[from the container.]
pass:v,q[Iterators to the last segment as well]
pass:v,q[as all end iterators are invalidated.]

=== Preconditions
[,cpp]
----
not this->empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-segments_ref]

= Class segments_ref

pass:v,q[A view representing path segments in a URL]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L85[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class segments_ref
    : public xref:boost-urls-segments_base[segments_base];
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-const_iterator[`pass:v[const_iterator]`] |
xref:boost-urls-segments_base-iterator[iterator]

|xref:boost-urls-segments_base-const_reference[`pass:v[const_reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_base-difference_type[`pass:v[difference_type]`] |
pass:v,q[A signed integer type used to represent differences.]

|xref:boost-urls-segments_base-iterator[`pass:v[iterator]`] |

|xref:boost-urls-segments_base-reference[`pass:v[reference]`] |
pass:v,q[The reference type]

|xref:boost-urls-segments_base-size_type[`pass:v[size_type]`] |
pass:v,q[An unsigned integer type used to represent size.]

|xref:boost-urls-segments_base-value_type[`pass:v[value_type]`] |
pass:v,q[The value type]

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_ref-assign[`pass:v[assign]`] |
pass:v,q[Assign segments]

|xref:boost-urls-segments_base-back[`pass:v[back]`] |
pass:v,q[Return the last segment]

|xref:boost-urls-segments_base-begin[`pass:v[begin]`] |
pass:v,q[Return an iterator to the beginning]

|xref:boost-urls-segments_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the referenced character buffer.]

|xref:boost-urls-segments_ref-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents of the container]

|xref:boost-urls-segments_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if there are no segments]

|xref:boost-urls-segments_base-end[`pass:v[end]`] |
pass:v,q[Return an iterator to the end]

|xref:boost-urls-segments_ref-erase[`pass:v[erase]`] |
pass:v,q[Erase segments]

|xref:boost-urls-segments_base-front[`pass:v[front]`] |
pass:v,q[Return the first segment]

|xref:boost-urls-segments_ref-insert[`pass:v[insert]`] |
pass:v,q[Insert segments]

|xref:boost-urls-segments_base-is_absolute[`pass:v[is_absolute]`] |
pass:v,q[Returns true if this references an absolute path.]

|xref:boost-urls-segments_ref-2conversion[`pass:v[operator segments_view]`] |
pass:v,q[Conversion]

|xref:boost-urls-segments_ref-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-segments_ref-pop_back[`pass:v[pop_back]`] |
pass:v,q[Remove the last segment]

|xref:boost-urls-segments_ref-push_back[`pass:v[push_back]`] |
pass:v,q[Append a segment]

|xref:boost-urls-segments_ref-replace[`pass:v[replace]`] |
pass:v,q[Replace segments]

|xref:boost-urls-segments_ref-2constructor[`pass:v[segments_ref]`] |
pass:v,q[Constructor]

|xref:boost-urls-segments_base-size[`pass:v[size]`] |
pass:v,q[Return the number of segments]

|xref:boost-urls-segments_ref-url[`pass:v[url]`] |
pass:v,q[Return the referenced url]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-segments_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===

== Description

pass:v,q[Objects of this type are used to interpret] pass:v,q[the path as a bidirectional view of segments,]
pass:v,q[where each segment is a string with percent]
pass:v,q[escapes automatically decoded.]
pass:v,q[The view does not retain ownership of the]
pass:v,q[elements and instead references the original]
pass:v,q[character buffer. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the buffer]
pass:v,q[extends until it is no longer referenced.]
pass:v,q[The view is modifiable; calling non-const]
pass:v,q[members causes changes to the referenced]
pass:v,q[url.]

=== Example
[,cpp]
----
url u( "/path/to/file.txt" );

segments_ref ps = u.segments();
----
pass:v,q[Percent escapes in strings returned when]
pass:v,q[dereferencing iterators are automatically]
pass:v,q[decoded.]
pass:v,q[Reserved characters in strings supplied]
pass:v,q[to modifier functions are automatically]
pass:v,q[percent-escaped.]

=== Iterator Invalidation
pass:v,q[Changes to the underlying character buffer]
pass:v,q[can invalidate iterators which reference it.]
pass:v,q[Modifications made through the container]
pass:v,q[invalidate some or all iterators:]

* xref:boost-urls-segments_ref-push_back[push_back]
pass:v,q[: Only `end()`.]

* xref:boost-urls-segments_ref-assign-08[assign,]
xref:boost-urls-segments_ref-clear[clear,]
xref:boost-urls-segments_ref-operator_assign-0d[operator=]
pass:v,q[: All elements.]

* xref:boost-urls-segments_ref-erase-0af2[erase]
pass:v,q[: Erased elements and all]
pass:v,q[elements after (including `end()`).]

* xref:boost-urls-segments_ref-insert-05[insert]
pass:v,q[: All elements at or after]
pass:v,q[the insertion point (including `end()`).]

* xref:boost-urls-segments_ref-replace-05[replace]
pass:v,q[: Modified]
pass:v,q[elements and all elements]
pass:v,q[after (including `end()`).]




[#boost-urls-segments_ref-2constructor]

= Function segments_ref::segments_ref

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L124[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_ref(const xref:boost-urls-segments_ref[segments_ref]& other) = default;
----

== Description

pass:v,q[After construction, both views] pass:v,q[reference the same url. Ownership is not]
pass:v,q[transferred; the caller is responsible]
pass:v,q[for ensuring the lifetime of the url]
pass:v,q[extends until it is no longer]
pass:v,q[referenced.]

=== Postconditions
[,cpp]
----
&this->url() == &other.url();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-segments_ref-operator_assign]

= Overload set segments_ref::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]&
operator=(const xref:boost-urls-segments_ref[segments_ref]& other);
  xref:boost-urls-segments_ref-operator_assign-0d[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]&
operator=(const xref:boost-urls-segments_view[segments_view]& other);
  xref:boost-urls-segments_ref-operator_assign-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]&
operator=(initializer_list<string_view> init);
  xref:boost-urls-segments_ref-operator_assign-0f[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_ref-2conversion]

= Function segments_ref::operator segments_view

pass:v,q[Conversion]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L214[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator xref:boost-urls-segments_view[segments_view]() const noexcept;
----


[#boost-urls-segments_ref-url]

= Function segments_ref::url

pass:v,q[Return the referenced url]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L238[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_base[url_base]&
url() const noexcept;
----

== Description

pass:v,q[This function returns the url referenced] pass:v,q[by the view.]

=== Example
[,cpp]
----
url u( "/path/to/file.txt" );

assert( &u.segments().url() == &u );
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-segments_ref-clear]

= Function segments_ref::clear

pass:v,q[Clear the contents of the container]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L271[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
clear() noexcept;
----

== Description

pass:v,q[All iterators are invalidated.]

=== Effects
[,cpp]
----
this->url().set_encoded_path( "" );
----

=== Postconditions
[,cpp]
----
this->empty() == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-segments_ref-assign]

= Overload set segments_ref::assign

== Members


pass:v,q[Assign segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<string_view> init);
  xref:boost-urls-segments_ref-assign-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assign segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
  xref:boost-urls-segments_ref-assign-0d[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_ref-insert]

= Overload set segments_ref::insert

== Members


pass:v,q[Insert segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
insert(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] before,
    string_view s);
  xref:boost-urls-segments_ref-insert-05[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
insert(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] before,
    initializer_list<string_view> init);
  xref:boost-urls-segments_ref-insert-09[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Insert segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
insert(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-segments_ref-insert-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_ref-erase]

= Overload set segments_ref::erase

== Members


pass:v,q[Erase segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
erase(xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] pos) noexcept;
  xref:boost-urls-segments_ref-erase-0af2[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Erase segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
erase(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] first,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] last) noexcept;
  xref:boost-urls-segments_ref-erase-0af5[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_ref-replace]

= Overload set segments_ref::replace

== Members


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] pos,
    string_view s);
  xref:boost-urls-segments_ref-replace-05[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] from,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] to,
    string_view s);
  xref:boost-urls-segments_ref-replace-04[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] from,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] to,
    initializer_list<string_view> init);
  xref:boost-urls-segments_ref-replace-02[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Replace segments]


[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] from,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
  xref:boost-urls-segments_ref-replace-07[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-segments_ref-push_back]

= Function segments_ref::push_back

pass:v,q[Append a segment]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L693[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
push_back(string_view s);
----

== Description

pass:v,q[This function appends a segment to] pass:v,q[the end of the path.] pass:v,q[Reserved characters in the string are]
pass:v,q[automatically escaped.]
pass:v,q[All end iterators are invalidated.]

=== Postconditions
[,cpp]
----
this->back() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-segments_ref-pop_back]

= Function segments_ref::pop_back

pass:v,q[Remove the last segment]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L714[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
pop_back() noexcept;
----

== Description

pass:v,q[This function removes the last segment] pass:v,q[from the container.]
pass:v,q[Iterators to the last segment as well]
pass:v,q[as all end iterators are invalidated.]

=== Preconditions
[,cpp]
----
not this->empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-url_view_base]

= Class url_view_base

pass:v,q[Common functionality for containers]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L65[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class url_view_base;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-authority[`pass:v[authority]`] |
pass:v,q[Return the authority]

|xref:boost-urls-url_view_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the url string]

|xref:boost-urls-url_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing this with another url]

|xref:boost-urls-url_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the url's character buffer]

|xref:boost-urls-url_view_base-digest[`pass:v[digest]`] |

|xref:boost-urls-url_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the url is empty]

|xref:boost-urls-url_view_base-encoded_authority[`pass:v[encoded_authority]`] |
pass:v,q[Return the authority.]

|xref:boost-urls-url_view_base-encoded_fragment[`pass:v[encoded_fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-encoded_host[`pass:v[encoded_host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_address[`pass:v[encoded_host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_and_port[`pass:v[encoded_host_and_port]`] |
pass:v,q[Return the host and port]

|xref:boost-urls-url_view_base-encoded_host_name[`pass:v[encoded_host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-encoded_origin[`pass:v[encoded_origin]`] |
pass:v,q[Return the origin]

|xref:boost-urls-url_view_base-encoded_params[`pass:v[encoded_params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-encoded_password[`pass:v[encoded_password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-encoded_path[`pass:v[encoded_path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-encoded_query[`pass:v[encoded_query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-encoded_resource[`pass:v[encoded_resource]`] |
pass:v,q[Return the resource]

|xref:boost-urls-url_view_base-encoded_segments[`pass:v[encoded_segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-encoded_target[`pass:v[encoded_target]`] |
pass:v,q[Return the target]

|xref:boost-urls-url_view_base-encoded_user[`pass:v[encoded_user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-encoded_userinfo[`pass:v[encoded_userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-encoded_zone_id[`pass:v[encoded_zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url_view_base-fragment[`pass:v[fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-has_authority[`pass:v[has_authority]`] |
pass:v,q[Return true if an authority is present]

|xref:boost-urls-url_view_base-has_fragment[`pass:v[has_fragment]`] |
pass:v,q[Return true if a fragment is present]

|xref:boost-urls-url_view_base-has_password[`pass:v[has_password]`] |
pass:v,q[Return true if a password is present]

|xref:boost-urls-url_view_base-has_port[`pass:v[has_port]`] |
pass:v,q[Return true if a port is present]

|xref:boost-urls-url_view_base-has_query[`pass:v[has_query]`] |
pass:v,q[Return true if a query is present]

|xref:boost-urls-url_view_base-has_scheme[`pass:v[has_scheme]`] |
pass:v,q[Return true a scheme is present]

|xref:boost-urls-url_view_base-has_userinfo[`pass:v[has_userinfo]`] |
pass:v,q[Return true if a userinfo is present]

|xref:boost-urls-url_view_base-host[`pass:v[host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_address[`pass:v[host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_ipv4_address[`pass:v[host_ipv4_address]`] |
pass:v,q[Return the host IPv4 address]

|xref:boost-urls-url_view_base-host_ipv6_address[`pass:v[host_ipv6_address]`] |
pass:v,q[Return the host IPv6 address]

|xref:boost-urls-url_view_base-host_ipvfuture[`pass:v[host_ipvfuture]`] |
pass:v,q[Return the host IPvFuture address]

|xref:boost-urls-url_view_base-host_name[`pass:v[host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-host_type[`pass:v[host_type]`] |
pass:v,q[Return the host type]

|xref:boost-urls-url_view_base-is_path_absolute[`pass:v[is_path_absolute]`] |
pass:v,q[Return true if the path is absolute]

|xref:boost-urls-url_view_base-2conversion[`pass:v[operator string_view]`] |
pass:v,q[Return the URL as a core::string_view]

|xref:boost-urls-url_view_base-params[`pass:v[params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-password[`pass:v[password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-path[`pass:v[path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-persist[`pass:v[persist]`] |
pass:v,q[Return a shared, persistent copy of the url]

|xref:boost-urls-url_view_base-port[`pass:v[port]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-port_number[`pass:v[port_number]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-query[`pass:v[query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-scheme[`pass:v[scheme]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-scheme_id[`pass:v[scheme_id]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-segments[`pass:v[segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-size[`pass:v[size]`] |
pass:v,q[Return the number of characters in the url]

|xref:boost-urls-url_view_base-user[`pass:v[user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-userinfo[`pass:v[userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-zone_id[`pass:v[zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-8friend-02[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-05[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-03[`pass:v[operator<<]`] |

|xref:boost-urls-url_view_base-8friend-04[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-07c[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-073[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-06[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two URLs]

|===

== Description

pass:v,q[This base class is used by the library] pass:v,q[to provide common member functions for]
pass:v,q[containers. This cannot be instantiated]
pass:v,q[directly; Instead, use one of the]
pass:v,q[containers or functions:]

=== Containers

* xref:boost-urls-url[url]

* xref:boost-urls-url_view[url_view]

* xref:boost-urls-static_url[static_url]

=== Functions

* xref:boost-urls-parse_absolute_uri[parse_absolute_uri]

* xref:boost-urls-parse_origin_form[parse_origin_form]

* xref:boost-urls-parse_relative_ref[parse_relative_ref]

* xref:boost-urls-parse_uri[parse_uri]

* xref:boost-urls-parse_uri_reference[parse_uri_reference]




[#boost-urls-url_view_base-digest]

= Function url_view_base::digest



== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L114[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
digest(size_t = 0) const noexcept;
----


[#boost-urls-url_view_base-max_size]

= Function url_view_base::max_size

pass:v,q[Return the maximum number of characters possible]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L139[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
size_t
max_size() noexcept;
----

== Description

pass:v,q[This represents the largest number] pass:v,q[of characters that are theoretically]
pass:v,q[possible to represent in a url,]
pass:v,q[not including any null terminator.]
pass:v,q[In practice the actual possible size]
pass:v,q[may be lower than this number.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-url_view_base-size]

= Function url_view_base::size

pass:v,q[Return the number of characters in the url]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L165[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
size() const noexcept;
----

== Description

pass:v,q[This function returns the number of] pass:v,q[characters in the url's encoded string,]
pass:v,q[not including any null terminator,]
pass:v,q[if present.]

=== Example
[,cpp]
----
assert( url_view( "file:///Program%20Files" ).size() == 23 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 





[#boost-urls-url_view_base-empty]

= Function url_view_base::empty

pass:v,q[Return true if the url is empty]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L201[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
empty() const noexcept;
----

== Description

pass:v,q[The empty string matches the] pass:v,q[relative-ref] pass:v,q[grammar.]

=== Example
[,cpp]
----
assert( url_view( "" ).empty() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
relative-ref  = relative-part [ "?" query ] [ "#" fragment ]

relative-part = "//" authority path-abempty
              / path-absolute
              / path-noscheme
              / path-empty
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.2[4.2.  Relative Reference (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-data]

= Function url_view_base::data

pass:v,q[Return a pointer to the url's character buffer]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L219[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
const char*
data() const noexcept;
----

== Description

pass:v,q[This function returns a pointer to] pass:v,q[the first character of the url, which]
pass:v,q[is not guaranteed to be null-terminated.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-url_view_base-buffer]

= Function url_view_base::buffer

pass:v,q[Return the url string]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L241[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
buffer() const noexcept;
----

== Description

pass:v,q[This function returns the entire url,] pass:v,q[which may contain percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com" ).buffer() == "http://www.example.com" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `string_view` 





[#boost-urls-url_view_base-2conversion]

= Function url_view_base::operator string_view

pass:v,q[Return the URL as a core::string_view]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L257[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
operator string_view() const noexcept;
----

== Description


=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `string_view` 





[#boost-urls-url_view_base-persist]

= Function url_view_base::persist

pass:v,q[Return a shared, persistent copy of the url]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L297[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
shared_ptr<const xref:boost-urls-url_view[url_view]>
persist() const;
----

== Description

pass:v,q[This function returns a read-only copy of] pass:v,q[the url, with shared lifetime. The returned]
pass:v,q[value owns (persists) the underlying string.]
pass:v,q[The algorithm used to create the value]
pass:v,q[minimizes the number of individual memory]
pass:v,q[allocations, making it more efficient than]
pass:v,q[when using direct standard library functions.]

=== Example
[,cpp]
----
std::shared_ptr< url_view const > sp;
{
    std::string s( "http://example.com" );
    url_view u( s );                        // u references characters in s

    assert( u.data() == s.data() );         // same buffer

    sp = u.persist();

    assert( sp->data() != s.data() );       // different buffer
    assert( sp->buffer() == s);             // same contents

    // s is destroyed and thus u
    // becomes invalid, but sp remains valid.
}
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `shared_ptr` 





[#boost-urls-url_view_base-has_scheme]

= Function url_view_base::has_scheme

pass:v,q[Return true a scheme is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L339[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_scheme() const noexcept;
----

== Description

pass:v,q[This function returns true if this] pass:v,q[contains a scheme.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com" ).has_scheme() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

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

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

scheme          = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[3.1. Scheme (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-scheme]

= Function url_view_base::scheme

pass:v,q[Return the scheme]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L375[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
scheme() const noexcept;
----

== Description

pass:v,q[This function returns the scheme if it] pass:v,q[exists, without a trailing colon (':').]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[Note that schemes are case-insensitive,]
pass:v,q[and the canonical form is lowercased.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com" ).scheme() == "http" );
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
scheme          = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )

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

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

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[3.1. Scheme (rfc3986)]



== Return Value

* `string_view` 





[#boost-urls-url_view_base-scheme_id]

= Function url_view_base::scheme_id

pass:v,q[Return the scheme]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L424[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-scheme[scheme]
scheme_id() const noexcept;
----

== Description

pass:v,q[This function returns a value which] pass:v,q[depends on the scheme in the url:]

* pass:v,q[If the scheme is a well-known]
pass:v,q[scheme, corresponding value from]
pass:v,q[the enumeration]
xref:boost-urls-scheme[urls::scheme]
pass:v,q[is returned.]

* pass:v,q[If a scheme is present but is not]
pass:v,q[a well-known scheme, the value]
pass:v,q[returned is]
xref:boost-urls-scheme-unknown[urls::scheme::unknown.]

* pass:v,q[Otherwise, if the scheme is absent]
pass:v,q[the value returned is]
xref:boost-urls-scheme-none[urls::scheme::none.]

=== Example
[,cpp]
----
assert( url_view( "wss://www.example.com/crypto.cgi" ).scheme_id() == scheme::wss );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

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

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

scheme          = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[3.1. Scheme (rfc3986)]



== Return Value

* `scheme` 





[#boost-urls-url_view_base-has_authority]

= Function url_view_base::has_authority

pass:v,q[Return true if an authority is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L480[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_authority() const noexcept;
----

== Description

pass:v,q[This function returns true if the url] pass:v,q[contains an authority. The presence of]
pass:v,q[an authority is denoted by a double]
pass:v,q[slash ("//") at the beginning or after]
pass:v,q[the scheme.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com/index.htm" ).has_authority() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority       = [ userinfo "@" ] host [ ":" port ]

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

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

URI-reference   = URI / relative-ref

relative-ref    = relative-part [ "?" query ] [ "#" fragment ]

hier-part       = "//" authority path-abempty
                ; (more...)

relative-part   = "//" authority path-abempty
                ; (more...)

----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[3.2. Authority (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-authority]

= Function url_view_base::authority

pass:v,q[Return the authority]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L515[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-authority_view[authority_view]
authority() const noexcept;
----

== Description

pass:v,q[This function returns the authority as] pass:v,q[an] xref:boost-urls-authority_view[authority_view.]

=== Example
[,cpp]
----
authority_view a = url_view( "https://www.example.com:8080/index.htm" ).authority();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[3.2. Authority (rfc3986)]



== Return Value

* `authority_view` 





[#boost-urls-url_view_base-encoded_authority]

= Function url_view_base::encoded_authority

pass:v,q[Return the authority.]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L551[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_authority() const noexcept;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the authority (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "file://Network%20Drive/My%2DFiles" ).encoded_authority() == "Network%20Drive" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[3.2. Authority (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-has_userinfo]

= Function url_view_base::has_userinfo

pass:v,q[Return true if a userinfo is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L597[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_userinfo() const noexcept;
----

== Description

pass:v,q[This function returns true if this] pass:v,q[contains a userinfo.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).has_userinfo() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-has_password]

= Function url_view_base::has_password

pass:v,q[Return true if a password is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L638[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_password() const noexcept;
----

== Description

pass:v,q[This function returns true if the] pass:v,q[userinfo is present and contains]
pass:v,q[a password.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).has_password() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-userinfo]

= Function url_view_base::userinfo

pass:v,q[Return the userinfo]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L696[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
userinfo(StringToken&& token) const;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the userinfo (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]
[NOTE]
pass:v,q[This function uses the string token]
pass:v,q[return type customization. Depending on]
pass:v,q[the token passed, the return type and]
pass:v,q[behavior of the function can be different.]
pass:v,q[See]
xref:boost-urls-string_token-return_string[string_token::return_string]
pass:v,q[for more information.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).userinfo() == "jane-doe:pass" );
----

=== Complexity
pass:v,q[Linear in `this->userinfo().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_userinfo]

= Function url_view_base::encoded_userinfo

pass:v,q[Return the userinfo]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L746[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_userinfo() const noexcept;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the userinfo (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).encoded_userinfo() == "jane%2Ddoe:pass" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-user]

= Function url_view_base::user

pass:v,q[Return the user]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L793[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
user(StringToken&& token) const;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the user (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).user() == "jane-doe" );
----

=== Complexity
pass:v,q[Linear in `this->user().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_user]

= Function url_view_base::encoded_user

pass:v,q[Return the user]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L844[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_user() const noexcept;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the user (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).encoded_user() == "jane%2Ddoe" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-password]

= Function url_view_base::password

pass:v,q[Return the password]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L889[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
password(StringToken&& token) const;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the password (which]
pass:v,q[may be an empty string).]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).password() == "pass" );
----

=== Complexity
pass:v,q[Linear in `this->password().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_password]

= Function url_view_base::encoded_password

pass:v,q[Return the password]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L936[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_password() const noexcept;
----

== Description

pass:v,q[This function returns the password portion] pass:v,q[of the userinfo as a percent-encoded string.]

=== Example
[,cpp]
----
assert( url_view( "http://jane%2Ddoe:pass@example.com" ).encoded_password() == "pass" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo    = user [ ":" [ password ] ]

user        = *( unreserved / pct-encoded / sub-delims )
password    = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[3.2.1. User Information (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-host_type]

= Function url_view_base::host_type

pass:v,q[Return the host type]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L975[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-host_type[host_type]
host_type() const noexcept;
----

== Description

pass:v,q[This function returns one of the] pass:v,q[following constants representing the]
pass:v,q[type of host present.]

* xref:boost-urls-host_type-ipv4[host_type::ipv4]

* xref:boost-urls-host_type-ipv6[host_type::ipv6]

* xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture]

* xref:boost-urls-host_type-name[host_type::name]

* xref:boost-urls-host_type-none[host_type::none]
pass:v,q[When]
xref:boost-urls-url_view_base-has_authority[has_authority]
pass:v,q[is false, the]
pass:v,q[host type is]
xref:boost-urls-host_type-none[host_type::none.]

=== Example
[,cpp]
----
assert( url_view( "https://192.168.0.1/local.htm" ).host_type() == host_type::ipv4 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `host_type` 





[#boost-urls-url_view_base-host]

= Function url_view_base::host

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1014[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
host(StringToken&& token) const;
----

== Description

pass:v,q[This function returns the host portion] pass:v,q[of the authority as a string, or the]
pass:v,q[empty string if there is no authority.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).host() == "www-root.example.com" );
----

=== Complexity
pass:v,q[Linear in `this->host().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_host]

= Function url_view_base::encoded_host

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1056[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host() const noexcept;
----

== Description

pass:v,q[This function returns the host portion] pass:v,q[of the authority as a string, or the]
pass:v,q[empty string if there is no authority.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).encoded_host() == "www%2droot.example.com" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-host_address]

= Function url_view_base::host_address

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1109[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
host_address(StringToken&& token) const;
----

== Description

pass:v,q[The value returned by this function] pass:v,q[depends on the type of host returned]
pass:v,q[from the function]
xref:boost-urls-url_view_base-host_type[host_type.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4,]
pass:v,q[then the IPv4 address string is returned.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6,]
pass:v,q[then the IPv6 address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture,]
pass:v,q[then the IPvFuture address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-name[host_type::name,]
pass:v,q[then the host name string is returned.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-none[host_type::none,]
pass:v,q[then an empty string is returned.]

=== Example
[,cpp]
----
assert( url_view( "https://[1::6:c0a8:1]/" ).host_address() == "1::6:c0a8:1" );
----

=== Complexity
pass:v,q[Linear in `this->host_address().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_host_address]

= Function url_view_base::encoded_host_address

pass:v,q[Return the host]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1170[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host_address() const noexcept;
----

== Description

pass:v,q[The value returned by this function] pass:v,q[depends on the type of host returned]
pass:v,q[from the function]
xref:boost-urls-url_view_base-host_type[host_type.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4,]
pass:v,q[then the IPv4 address string is returned.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6,]
pass:v,q[then the IPv6 address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture,]
pass:v,q[then the IPvFuture address string is returned,]
pass:v,q[without any enclosing brackets.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-name[host_type::name,]
pass:v,q[then the host name string is returned.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

* pass:v,q[If the type is]
xref:boost-urls-host_type-none[host_type::none,]
pass:v,q[then an empty string is returned.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).encoded_host_address() == "www%2droot.example.com" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-host_ipv4_address]

= Function url_view_base::host_ipv4_address

pass:v,q[Return the host IPv4 address]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1209[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-ipv4_address[ipv4_address]
host_ipv4_address() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipv4[host_type::ipv4,] pass:v,q[this function returns the address as]
pass:v,q[a value of type]
xref:boost-urls-ipv4_address[ipv4_address.]
pass:v,q[Otherwise, if the host type is not an IPv4]
pass:v,q[address, it returns a default-constructed]
pass:v,q[value which is equal to the unspecified]
pass:v,q[address "0.0.0.0".]

=== Example
[,cpp]
----
assert( url_view( "http://127.0.0.1/index.htm?user=win95" ).host_ipv4_address() == ipv4_address( "127.0.0.1" ) );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `ipv4_address` 





[#boost-urls-url_view_base-host_ipv6_address]

= Function url_view_base::host_ipv6_address

pass:v,q[Return the host IPv6 address]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1256[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-ipv6_address[ipv6_address]
host_ipv6_address() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipv6[host_type::ipv6,] pass:v,q[this function returns the address as]
pass:v,q[a value of type]
xref:boost-urls-ipv6_address[ipv6_address.]
pass:v,q[Otherwise, if the host type is not an IPv6]
pass:v,q[address, it returns a default-constructed]
pass:v,q[value which is equal to the unspecified]
pass:v,q[address "0:0:0:0:0:0:0:0".]

=== Example
[,cpp]
----
assert( url_view( "ftp://[::1]/" ).host_ipv6_address() == ipv6_address( "::1" ) );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `ipv6_address` 





[#boost-urls-url_view_base-host_ipvfuture]

= Function url_view_base::host_ipvfuture

pass:v,q[Return the host IPvFuture address]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1288[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
host_ipvfuture() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture,]
pass:v,q[this function returns the address as]
pass:v,q[a string.]
pass:v,q[Otherwise, if the host type is not an]
pass:v,q[IPvFuture address, it returns an]
pass:v,q[empty string.]

=== Example
[,cpp]
----
assert( url_view( "http://[v1fe.d:9]/index.htm" ).host_ipvfuture() == "v1fe.d:9" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
IPvFuture  = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `string_view` 





[#boost-urls-url_view_base-host_name]

= Function url_view_base::host_name

pass:v,q[Return the host name]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1324[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
host_name(StringToken&& token) const;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-name[host_type::name,] pass:v,q[this function returns the name as]
pass:v,q[a string. Otherwise an empty string is returned.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).host_name() == "www-root.example.com" );
----

=== Complexity
pass:v,q[Linear in `this->host_name().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_host_name]

= Function url_view_base::encoded_host_name

pass:v,q[Return the host name]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1368[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host_name() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-name[host_type::name,] pass:v,q[this function returns the name as]
pass:v,q[a string.]
pass:v,q[Otherwise, if the host type is not an]
pass:v,q[name, it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "https://www%2droot.example.com/" ).encoded_host_name() == "www%2droot.example.com" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-zone_id]

= Function url_view_base::zone_id

pass:v,q[Return the IPv6 Zone ID]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1406[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
zone_id(StringToken&& token) const;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipv6[host_type::ipv6,] pass:v,q[this function returns the Zone ID as]
pass:v,q[a string. Otherwise an empty string is returned.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "http://[fe80::1%25eth0]/" ).zone_id() == "eth0" );
----

=== Complexity
pass:v,q[Linear in `this->encoded_zone_id().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal = "[" ( IPv6address / IPv6addrz / IPvFuture  ) "]"

ZoneID = 1*( unreserved / pct-encoded )

IPv6addrz = IPv6address "%25" ZoneID
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc6874[Representing IPv6 Zone Identifiers in Address Literals and Uniform Resource Identifiers]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_zone_id]

= Function url_view_base::encoded_zone_id

pass:v,q[Return the IPv6 Zone ID]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1450[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_zone_id() const noexcept;
----

== Description

pass:v,q[If the host type is] xref:boost-urls-host_type-ipv6[host_type::ipv6,] pass:v,q[this function returns the Zone ID as]
pass:v,q[a string. Otherwise an empty string is returned.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://[fe80::1%25eth0]/" ).encoded_zone_id() == "eth0" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal = "[" ( IPv6address / IPv6addrz / IPvFuture  ) "]"

ZoneID = 1*( unreserved / pct-encoded )

IPv6addrz = IPv6address "%25" ZoneID
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc6874[Representing IPv6 Zone Identifiers in Address Literals and Uniform Resource Identifiers]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-has_port]

= Function url_view_base::has_port

pass:v,q[Return true if a port is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1491[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_port() const noexcept;
----

== Description

pass:v,q[This function returns true if an] pass:v,q[authority is present and contains a port.]

=== Example
[,cpp]
----
assert( url_view( "wss://www.example.com:443" ).has_port() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority   = [ userinfo "@" ] host [ ":" port ]

port        = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-port]

= Function url_view_base::port

pass:v,q[Return the port]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1526[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
string_view
port() const noexcept;
----

== Description

pass:v,q[If present, this function returns a] pass:v,q[string representing the port (which]
pass:v,q[may be empty).]
pass:v,q[Otherwise it returns an empty string.]

=== Example
[,cpp]
----
assert( url_view( "http://localhost.com:8080" ).port() == "8080" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
port        = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `string_view` 





[#boost-urls-url_view_base-port_number]

= Function url_view_base::port_number

pass:v,q[Return the port]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1561[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
uint16_t
port_number() const noexcept;
----

== Description

pass:v,q[If a port is present and the numerical] pass:v,q[value is representable, it is returned]
pass:v,q[as an unsigned integer. Otherwise, the]
pass:v,q[number zero is returned.]

=== Example
[,cpp]
----
assert( url_view( "http://localhost.com:8080" ).port_number() == 8080 );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
port        = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `uint16_t` 





[#boost-urls-url_view_base-is_path_absolute]

= Function url_view_base::is_path_absolute

pass:v,q[Return true if the path is absolute]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1611[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
is_path_absolute() const noexcept;
----

== Description

pass:v,q[This function returns true if the path] pass:v,q[begins with a forward slash ('/').]

=== Example
[,cpp]
----
assert( url_view( "/path/to/file.txt" ).is_path_absolute() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-path]

= Function url_view_base::path

pass:v,q[Return the path]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1663[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
path(StringToken&& token) const;
----

== Description

pass:v,q[This function returns the path as a] pass:v,q[string. The path may be empty.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "file:///Program%20Files/Games/config.ini" ).path() == "/Program Files/Games/config.ini" );
----

=== Complexity
pass:v,q[Linear in `this->path().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_path]

= Function url_view_base::encoded_path

pass:v,q[Return the path]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1716[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_path() const noexcept;
----

== Description

pass:v,q[This function returns the path as a] pass:v,q[string. The path may be empty.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]

=== Example
[,cpp]
----
assert( url_view( "file:///Program%20Files/Games/config.ini" ).encoded_path() == "/Program%20Files/Games/config.ini" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-segments]

= Function url_view_base::segments

pass:v,q[Return the path as a container of segments]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1756[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_view[segments_view]
segments() const noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of strings over the path.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Any percent-escapes in strings returned]
pass:v,q[when iterating the view are decoded first.]

=== Example
[,cpp]
----
segments_view sv = url_view( "/path/to/file.txt" ).segments();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = [ "/" ] segment *( "/" segment )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]



== Return Value

* `segments_view` 





[#boost-urls-url_view_base-encoded_segments]

= Function url_view_base::encoded_segments

pass:v,q[Return the path as a container of segments]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1806[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_view[segments_encoded_view]
encoded_segments() const noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of strings over the path.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Strings returned when iterating the]
pass:v,q[range may contain percent escapes.]

=== Example
[,cpp]
----
segments_encoded_view sv = url_view( "/path/to/file.txt" ).encoded_segments();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]



== Return Value

* `segments_encoded_view` 





[#boost-urls-url_view_base-has_query]

= Function url_view_base::has_query

pass:v,q[Return true if a query is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1852[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_query() const noexcept;
----

== Description

pass:v,q[This function returns true if this] pass:v,q[contains a query. An empty query is]
pass:v,q[distinct from having no query.]

=== Example
[,cpp]
----
assert( url_view( "/sql?id=42&col=name&page-size=20" ).has_query() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-query]

= Function url_view_base::query

pass:v,q[Return the query]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1901[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
query(StringToken&& token) const;
----

== Description

pass:v,q[If this contains a query, it is returned] pass:v,q[as a string (which may be empty).]
pass:v,q[Otherwise, an empty string is returned.]
pass:v,q[Any percent-escapes in the string are]
pass:v,q[decoded first.]
pass:v,q[When plus signs appear in the query]
pass:v,q[portion of the url, they are converted]
pass:v,q[to spaces automatically upon decoding.]
pass:v,q[This behavior can be changed by setting]
pass:v,q[decode options.]

=== Example
[,cpp]
----
assert( url_view( "/sql?id=42&name=jane%2Ddoe&page+size=20" ).query() == "id=42&name=jane-doe&page size=20" );
----

=== Complexity
pass:v,q[Linear in `this->query().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_query]

= Function url_view_base::encoded_query

pass:v,q[Return the query]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1953[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_query() const noexcept;
----

== Description

pass:v,q[If this contains a query, it is returned] pass:v,q[as a string (which may be empty).]
pass:v,q[Otherwise, an empty string is returned.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "/sql?id=42&name=jane%2Ddoe&page+size=20" ).encoded_query() == "id=42&name=jane%2Ddoe&page+size=20" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-params]

= Overload set url_view_base::params

== Members


pass:v,q[Return the query as a container of parameters]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_view[params_view]
params() const noexcept;
  xref:boost-urls-url_view_base-params-06[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_view[params_view]
params(xref:boost-urls-encoding_opts[encoding_opts] opt) const noexcept;
  xref:boost-urls-url_view_base-params-05[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url_view_base-encoded_params]

= Function url_view_base::encoded_params

pass:v,q[Return the query as a container of parameters]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2048[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_view[params_encoded_view]
encoded_params() const noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of key/value pairs over the query.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Strings returned when iterating the]
pass:v,q[range may contain percent escapes.]

=== Example
[,cpp]
----
params_encoded_view pv = url_view( "/sql?id=42&name=jane%2Ddoe&page+size=20" ).encoded_params();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `params_encoded_view` 





[#boost-urls-url_view_base-has_fragment]

= Function url_view_base::has_fragment

pass:v,q[Return true if a fragment is present]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2090[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
has_fragment() const noexcept;
----

== Description

pass:v,q[This function returns true if the url] pass:v,q[contains a fragment.] pass:v,q[An empty fragment is distinct from]
pass:v,q[no fragment.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com/index.htm#anchor" ).has_fragment() );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

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

relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5. Fragment (rfc3986)]



== Return Value

* `bool` 





[#boost-urls-url_view_base-fragment]

= Function url_view_base::fragment

pass:v,q[Return the fragment]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2149[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string]>
StringToken::result_type
fragment(StringToken&& token) const;
----

== Description

pass:v,q[This function calculates the fragment] pass:v,q[of the url, with percent escapes decoded]
pass:v,q[and without the leading pound sign ('#')]
pass:v,q[whose presence indicates that the url]
pass:v,q[contains a fragment.]
pass:v,q[This function accepts an optional]
pass:v,q[StringToken]
pass:v,q[parameter which]
pass:v,q[controls the return type and behavior]
pass:v,q[of the function:]

* pass:v,q[When called with no arguments,]
pass:v,q[the return type of the function is]
pass:v,q[`std::string`. Otherwise]

* pass:v,q[When called with a string token,]
pass:v,q[the behavior and return type of the]
pass:v,q[function depends on the type of string]
pass:v,q[token being passed.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com/index.htm#a%2D1" ).fragment() == "a-1" );
----

=== Complexity
pass:v,q[Linear in `this->fragment().size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]
pass:v,q[String tokens may throw exceptions.]

=== BNF
[,cpp]
----
fragment        = *( pchar / "/" / "?" )

fragment-part   = [ "#" fragment ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5. Fragment (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *token*
| ``

|===




[#boost-urls-url_view_base-encoded_fragment]

= Function url_view_base::encoded_fragment

pass:v,q[Return the fragment]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2194[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_fragment() const noexcept;
----

== Description

pass:v,q[This function returns the fragment as a] pass:v,q[string with percent-escapes.]
pass:v,q[Ownership is not transferred; the]
pass:v,q[string returned references the underlying]
pass:v,q[character buffer, which must remain valid]
pass:v,q[or else undefined behavior occurs.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com/index.htm#a%2D1" ).encoded_fragment() == "a%2D1" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
fragment        = *( pchar / "/" / "?" )

pchar           = unreserved / pct-encoded / sub-delims / ":" / "@"
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5. Fragment (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-encoded_host_and_port]

= Function url_view_base::encoded_host_and_port

pass:v,q[Return the host and port]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2239[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_host_and_port() const noexcept;
----

== Description

pass:v,q[If an authority is present, this] pass:v,q[function returns the host and optional]
pass:v,q[port as a string, which may be empty.]
pass:v,q[Otherwise it returns an empty string.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com:8080/index.htm" ).encoded_host_and_port() == "www.example.com:8080" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority   = [ userinfo "@" ] host [ ":" port ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2.  Host (rfc3986)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[3.2.3. Port (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-encoded_origin]

= Function url_view_base::encoded_origin

pass:v,q[Return the origin]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2267[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_origin() const noexcept;
----

== Description

pass:v,q[If an authority is present, this] pass:v,q[function returns the scheme and]
pass:v,q[authority portion of the url.]
pass:v,q[Otherwise, an empty string is]
pass:v,q[returned.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com:8080/index.htm?text=none#h1" ).encoded_origin() == "http://www.example.com:8080" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-encoded_resource]

= Function url_view_base::encoded_resource

pass:v,q[Return the resource]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2299[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_resource() const noexcept;
----

== Description

pass:v,q[This function returns the resource, which] pass:v,q[is the portion of the url that includes]
pass:v,q[only the path, query, and fragment.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com/index.html?query#frag" ).encoded_resource() == "/index.html?query#frag" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-encoded_target]

= Function url_view_base::encoded_target

pass:v,q[Return the target]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2331[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-pct_string_view[pct_string_view]
encoded_target() const noexcept;
----

== Description

pass:v,q[This function returns the target, which] pass:v,q[is the portion of the url that includes]
pass:v,q[only the path and query.]
pass:v,q[The returned string may contain]
pass:v,q[percent escapes.]

=== Example
[,cpp]
----
assert( url_view( "http://www.example.com/index.html?query#frag" ).encoded_target() == "/index.html?query" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)]



== Return Value

* `pct_string_view` 





[#boost-urls-url_view_base-compare]

= Function url_view_base::compare

pass:v,q[Return the result of comparing this with another url]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2359[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
int
compare(const xref:boost-urls-url_view_base[url_view_base]& other) const noexcept;
----

== Description

pass:v,q[This function compares two URLs] pass:v,q[according to Syntax-Based comparison]
pass:v,q[algorithm.]

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-url_view_base-8friend-07c]

= Friend operator==

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2413[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator==(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.a.com/index.htm" );
assert( u0 == u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) ==
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



[#boost-urls-url_view_base-8friend-02]

= Friend operator!=

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2473[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator!=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.b.com/index.htm" );
assert( u0 != u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) !=
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



[#boost-urls-url_view_base-8friend-05]

= Friend operator<

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2533[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator<(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.b.com/index.htm" );
assert( u0 < u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) <
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



[#boost-urls-url_view_base-8friend-04]

= Friend operator<=

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2593[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator<=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.b.com/index.htm" );
url_view u1( "http://www.b.com/index.htm" );
assert( u0 <= u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) <=
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



[#boost-urls-url_view_base-8friend-073]

= Friend operator>

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2653[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator>(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.b.com/index.htm" );
url_view u1( "http://www.a.com/index.htm" );
assert( u0 > u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) >
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



[#boost-urls-url_view_base-8friend-06]

= Friend operator>=

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2713[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
bool
operator>=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.a.com/index.htm" );
assert( u0 >= u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) >=
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



[#boost-urls-url_view_base-8friend-03]

= Friend operator<<



== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2722[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-url_view_base[url_view_base]& u);
----


[#boost-urls-resolve]

= Function resolve

pass:v,q[Resolve a URL reference against a base URL]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2744[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<void>
resolve(
    const xref:boost-urls-url_view_base[url_view_base]& base,
    const xref:boost-urls-url_view_base[url_view_base]& ref,
    xref:boost-urls-url_base[url_base]& dest);
----

== Description

pass:v,q[This function attempts to resolve a URL] pass:v,q[reference `ref` against the base URL `base`]
pass:v,q[in a manner similar to that of a web browser]
pass:v,q[resolving an anchor tag.]
pass:v,q[The base URL must satisfy the]
pass:v,q[URI]
pass:v,q[grammar. In other words, it must contain]
pass:v,q[a scheme.]
pass:v,q[Relative references are only usable when]
pass:v,q[in the context of a base absolute URI.]
pass:v,q[This process of resolving a relative]
pass:v,q[reference]
pass:v,q[within the context of]
pass:v,q[a]
pass:v,q[base]
pass:v,q[URI is defined in detail]
pass:v,q[in rfc3986 (see below).]
pass:v,q[The resolution process works as if the]
pass:v,q[relative reference is appended to the base]
pass:v,q[URI and the result is normalized.]
pass:v,q[Given the input base URL, this function]
pass:v,q[resolves the relative reference]
pass:v,q[as if performing the following steps:]

* pass:v,q[Ensure the base URI has at least a scheme]

* pass:v,q[Normalizing the reference path]

* pass:v,q[Merge base and reference paths]

* pass:v,q[Normalize the merged path]
pass:v,q[This function places the result of the]
pass:v,q[resolution into `dest`, which can be]
pass:v,q[any of the url containers that inherit]
pass:v,q[from]
xref:boost-urls-url_base[url_base.]
pass:v,q[If an error occurs, the contents of]
pass:v,q[`dest` is unspecified and `ec` is set.]

=== Example
[,cpp]
----
url dest;
system::error_code ec;

resolve("/one/two/three", "four", dest, ec);
assert( dest.str() == "/one/two/four" );

resolve("http://example.com/", "/one", dest, ec);
assert( dest.str() == "http://example.com/one" );

resolve("http://example.com/one", "/two", dest, ec);
assert( dest.str() == "http://example.com/two" );

resolve("http://a/b/c/d;p?q", "g#s", dest, ec);
assert( dest.str() == "http://a/b/c/g#s" );
----

=== BNF
[,cpp]
----
absolute-URI  = scheme ":" hier-part [ "?" query ]
----

=== Exception Safety
pass:v,q[Basic guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification
link:https://datatracker.ietf.org/doc/html/rfc3986#section-5[5. Reference Resolution (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *base*
| ``

| *ref*
| ``

| *dest*
| ``

|===




[#boost-urls-url]

= Class url

pass:v,q[A modifiable container for a URL.]


== Synopsis

Declared in header `</boost/url/url.hpp#L63[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class url
    : public xref:boost-urls-url_base[url_base];
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-authority[`pass:v[authority]`] |
pass:v,q[Return the authority]

|xref:boost-urls-url_view_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the url string]

|xref:boost-urls-url_base-c_str[`pass:v[c_str]`] |
pass:v,q[Return the url as a null-terminated string]

|xref:boost-urls-url_base-capacity[`pass:v[capacity]`] |
pass:v,q[Return the number of characters that can be stored without reallocating]

|xref:boost-urls-url_base-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents while preserving the capacity]

|xref:boost-urls-url_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing this with another url]

|xref:boost-urls-url_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the url's character buffer]

|xref:boost-urls-url_view_base-digest[`pass:v[digest]`] |

|xref:boost-urls-url_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the url is empty]

|xref:boost-urls-url_view_base-encoded_authority[`pass:v[encoded_authority]`] |
pass:v,q[Return the authority.]

|xref:boost-urls-url_view_base-encoded_fragment[`pass:v[encoded_fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-encoded_host[`pass:v[encoded_host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_address[`pass:v[encoded_host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_and_port[`pass:v[encoded_host_and_port]`] |
pass:v,q[Return the host and port]

|xref:boost-urls-url_view_base-encoded_host_name[`pass:v[encoded_host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-encoded_origin[`pass:v[encoded_origin]`] |
pass:v,q[Return the origin]

|xref:boost-urls-url_view_base-encoded_params[`pass:v[encoded_params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-encoded_password[`pass:v[encoded_password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-encoded_path[`pass:v[encoded_path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-encoded_query[`pass:v[encoded_query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-encoded_resource[`pass:v[encoded_resource]`] |
pass:v,q[Return the resource]

|xref:boost-urls-url_view_base-encoded_segments[`pass:v[encoded_segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-encoded_target[`pass:v[encoded_target]`] |
pass:v,q[Return the target]

|xref:boost-urls-url_view_base-encoded_user[`pass:v[encoded_user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-encoded_userinfo[`pass:v[encoded_userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-encoded_zone_id[`pass:v[encoded_zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url_view_base-fragment[`pass:v[fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-has_authority[`pass:v[has_authority]`] |
pass:v,q[Return true if an authority is present]

|xref:boost-urls-url_view_base-has_fragment[`pass:v[has_fragment]`] |
pass:v,q[Return true if a fragment is present]

|xref:boost-urls-url_view_base-has_password[`pass:v[has_password]`] |
pass:v,q[Return true if a password is present]

|xref:boost-urls-url_view_base-has_port[`pass:v[has_port]`] |
pass:v,q[Return true if a port is present]

|xref:boost-urls-url_view_base-has_query[`pass:v[has_query]`] |
pass:v,q[Return true if a query is present]

|xref:boost-urls-url_view_base-has_scheme[`pass:v[has_scheme]`] |
pass:v,q[Return true a scheme is present]

|xref:boost-urls-url_view_base-has_userinfo[`pass:v[has_userinfo]`] |
pass:v,q[Return true if a userinfo is present]

|xref:boost-urls-url_view_base-host[`pass:v[host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_address[`pass:v[host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_ipv4_address[`pass:v[host_ipv4_address]`] |
pass:v,q[Return the host IPv4 address]

|xref:boost-urls-url_view_base-host_ipv6_address[`pass:v[host_ipv6_address]`] |
pass:v,q[Return the host IPv6 address]

|xref:boost-urls-url_view_base-host_ipvfuture[`pass:v[host_ipvfuture]`] |
pass:v,q[Return the host IPvFuture address]

|xref:boost-urls-url_view_base-host_name[`pass:v[host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-host_type[`pass:v[host_type]`] |
pass:v,q[Return the host type]

|xref:boost-urls-url_view_base-is_path_absolute[`pass:v[is_path_absolute]`] |
pass:v,q[Return true if the path is absolute]

|xref:boost-urls-url_base-normalize[`pass:v[normalize]`] |
pass:v,q[Normalize the URL components]

|xref:boost-urls-url_base-normalize_authority[`pass:v[normalize_authority]`] |
pass:v,q[Normalize the URL authority]

|xref:boost-urls-url_base-normalize_fragment[`pass:v[normalize_fragment]`] |
pass:v,q[Normalize the URL fragment]

|xref:boost-urls-url_base-normalize_path[`pass:v[normalize_path]`] |
pass:v,q[Normalize the URL path]

|xref:boost-urls-url_base-normalize_query[`pass:v[normalize_query]`] |
pass:v,q[Normalize the URL query]

|xref:boost-urls-url_base-normalize_scheme[`pass:v[normalize_scheme]`] |
pass:v,q[Normalize the URL scheme]

|xref:boost-urls-url_view_base-2conversion[`pass:v[operator string_view]`] |
pass:v,q[Return the URL as a core::string_view]

|xref:boost-urls-url-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-url_view_base-params[`pass:v[params]`] |
pass:v,q[Return the query as a container of parameters]

xref:boost-urls-url_view_base-params-05[url_view_base::params]

|xref:boost-urls-url_view_base-password[`pass:v[password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-path[`pass:v[path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-persist[`pass:v[persist]`] |
pass:v,q[Return a shared, persistent copy of the url]

|xref:boost-urls-url_view_base-port[`pass:v[port]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-port_number[`pass:v[port_number]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-query[`pass:v[query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_base-remove_authority[`pass:v[remove_authority]`] |
pass:v,q[Remove the authority]

|xref:boost-urls-url_base-remove_fragment[`pass:v[remove_fragment]`] |
pass:v,q[Remove the fragment]

|xref:boost-urls-url_base-remove_origin[`pass:v[remove_origin]`] |
pass:v,q[Remove the origin component]

|xref:boost-urls-url_base-remove_password[`pass:v[remove_password]`] |
pass:v,q[Remove the password]

|xref:boost-urls-url_base-remove_port[`pass:v[remove_port]`] |
pass:v,q[Remove the port]

|xref:boost-urls-url_base-remove_query[`pass:v[remove_query]`] |
pass:v,q[Remove the query]

|xref:boost-urls-url_base-remove_scheme[`pass:v[remove_scheme]`] |
pass:v,q[Remove the scheme]

|xref:boost-urls-url_base-remove_userinfo[`pass:v[remove_userinfo]`] |
pass:v,q[Remove the userinfo]

|xref:boost-urls-url_base-reserve[`pass:v[reserve]`] |
pass:v,q[Adjust the capacity without changing the size]

|xref:boost-urls-url_base-resolve[`pass:v[resolve]`] |
pass:v,q[Resolve a URL reference against this base URL]

|xref:boost-urls-url_view_base-scheme[`pass:v[scheme]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-scheme_id[`pass:v[scheme_id]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-segments[`pass:v[segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_base-set_encoded_authority[`pass:v[set_encoded_authority]`] |
pass:v,q[Set the authority]

|xref:boost-urls-url_base-set_encoded_fragment[`pass:v[set_encoded_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_encoded_host[`pass:v[set_encoded_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_encoded_host_address[`pass:v[set_encoded_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_encoded_host_name[`pass:v[set_encoded_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_encoded_params[`pass:v[set_encoded_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_encoded_password[`pass:v[set_encoded_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_encoded_path[`pass:v[set_encoded_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_encoded_query[`pass:v[set_encoded_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_encoded_user[`pass:v[set_encoded_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_encoded_userinfo[`pass:v[set_encoded_userinfo]`] |
pass:v,q[Set the userinfo.]

|xref:boost-urls-url_base-set_fragment[`pass:v[set_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_host[`pass:v[set_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_host_address[`pass:v[set_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv4[`pass:v[set_host_ipv4]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv6[`pass:v[set_host_ipv6]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipvfuture[`pass:v[set_host_ipvfuture]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_name[`pass:v[set_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_params[`pass:v[set_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_password[`pass:v[set_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_path[`pass:v[set_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_path_absolute[`pass:v[set_path_absolute]`] |
pass:v,q[Set if the path is absolute]

|xref:boost-urls-url_base-set_port[`pass:v[set_port]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_port_number[`pass:v[set_port_number]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_query[`pass:v[set_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_scheme[`pass:v[set_scheme]`] |
pass:v,q[Set the scheme]

|xref:boost-urls-url_base-set_scheme_id[`pass:v[set_scheme_id]`] |
xref:boost-urls-url_base-set_scheme_id[url_base::set_scheme_id]

|xref:boost-urls-url_base-set_user[`pass:v[set_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_userinfo[`pass:v[set_userinfo]`] |
pass:v,q[Set the userinfo]

|xref:boost-urls-url_view_base-size[`pass:v[size]`] |
pass:v,q[Return the number of characters in the url]

|xref:boost-urls-url-swap[`pass:v[swap]`] |
pass:v,q[Swap the contents.]

|xref:boost-urls-url-2constructor[`pass:v[url]`] |
pass:v,q[Constructor]

|xref:boost-urls-url_view_base-user[`pass:v[user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-userinfo[`pass:v[userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-zone_id[`pass:v[zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url-2destructor[`pass:v[~url]`] |
pass:v,q[Destructor]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-8friend-02[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-05[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-03[`pass:v[operator<<]`] |

|xref:boost-urls-url_view_base-8friend-04[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-07c[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-073[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-06[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_base-8friend[`pass:v[resolve]`] |

|xref:boost-urls-url-8friend[`pass:v[swap]`] |
pass:v,q[Swap]

|===

== Description

pass:v,q[This container owns a url, represented] pass:v,q[by a null-terminated character buffer]
pass:v,q[which is managed by performing dymamic]
pass:v,q[memory allocations as needed.]
pass:v,q[The contents may be inspected and modified,]
pass:v,q[and the implementation maintains a useful]
pass:v,q[invariant: changes to the url always]
pass:v,q[leave it in a valid state.]

=== Exception Safety

* pass:v,q[Functions marked `noexcept` provide the]
pass:v,q[no-throw guarantee, otherwise:]

* pass:v,q[Functions which throw offer the strong]
pass:v,q[exception safety guarantee.]

=== BNF
[,cpp]
----
URI-reference = URI / relative-ref

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

relative-ref  = relative-part [ "?" query ] [ "#" fragment ]

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

=== Specification

* link:https://tools.ietf.org/html/rfc3986[Uniform Resource Identifier (URI): Generic Syntax (rfc3986)]




[#boost-urls-url-2destructor]

= Function url::~url

pass:v,q[Destructor]


== Synopsis

Declared in header `</boost/url/url.hpp#L85[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
~url();
----

== Description

pass:v,q[Any params, segments, iterators, or] pass:v,q[views which reference this object are]
pass:v,q[invalidated. The underlying character]
pass:v,q[buffer is destroyed, invalidating all]
pass:v,q[references to it.]



== Return Value

* `void` 





[#boost-urls-url-2constructor]

= Overload set url::url

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url() noexcept = default;
  xref:boost-urls-url-2constructor-0f0[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url(string_view s);
  xref:boost-urls-url-2constructor-002[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url(xref:boost-urls-url[url]&& u) noexcept;
  xref:boost-urls-url-2constructor-01[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url(const xref:boost-urls-url_view_base[url_view_base]& u);
  xref:boost-urls-url-2constructor-001[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
url(const xref:boost-urls-url[url]& u);
  xref:boost-urls-url-2constructor-0f7[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url-operator_assign]

= Overload set url::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
operator=(xref:boost-urls-url[url]&& u) noexcept;
  xref:boost-urls-url-operator_assign-09[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
operator=(const xref:boost-urls-url_view_base[url_view_base]& u);
  xref:boost-urls-url-operator_assign-0b[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
operator=(const xref:boost-urls-url[url]& u);
  xref:boost-urls-url-operator_assign-06[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-url-swap]

= Function url::swap

pass:v,q[Swap the contents.]


== Synopsis

Declared in header `</boost/url/url.hpp#L360[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
swap(xref:boost-urls-url[url]& other) noexcept;
----

== Description

pass:v,q[Exchanges the contents of this url with another] pass:v,q[url. All views, iterators and references remain valid.]
pass:v,q[If `this ==]
pass:v,q[&other]
pass:v,q[`, this function call has no effect.]

=== Example
[,cpp]
----
url u1( "https://www.example.com" );
url u2( "https://www.boost.org" );
u1.swap(u2);
assert(u1 == "https://www.boost.org" );
assert(u2 == "https://www.example.com" );
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-url-8friend]

= Friend swap

pass:v,q[Swap]


== Synopsis

Declared in header `</boost/url/url.hpp#L396[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
friend
void
swap(
    xref:boost-urls-url[url]& v0,
    xref:boost-urls-url[url]& v1) noexcept;
----

== Description

pass:v,q[Exchanges the contents of `v0` with another `v1`.] pass:v,q[All views, iterators and references remain]
pass:v,q[valid.]
pass:v,q[If `]
pass:v,q[&v]
pass:v,q[0 ==]
pass:v,q[&v]
pass:v,q[1`, this function call has no effect.]

=== Example
[,cpp]
----
url u1( "https://www.example.com" );
url u2( "https://www.boost.org" );
std::swap(u1, u2);
assert(u1 == "https://www.boost.org" );
assert(u2 == "https://www.example.com" );
----

=== Effects
[,cpp]
----
v0.swap( v1 );
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



[#boost-urls-url-set_scheme]

= Function url::set_scheme

pass:v,q[Set the scheme]


== Synopsis

Declared in header `</boost/url/url.hpp#L409[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_scheme(string_view s);
----

== Description

pass:v,q[The scheme is set to the specified] pass:v,q[string, which must contain a valid]
pass:v,q[scheme without any trailing colon]
pass:v,q[(':').]
pass:v,q[Note that schemes are case-insensitive,]
pass:v,q[and the canonical form is lowercased.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_scheme( "https" ).scheme_id() == scheme::https );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
scheme        = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[            3.1. Scheme (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_scheme_id]

= Function url::set_scheme_id

xref:boost-urls-url_base-set_scheme_id[url_base::set_scheme_id]


== Synopsis

Declared in header `</boost/url/url.hpp#L411[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_scheme_id(xref:boost-urls-scheme[scheme] id);
----


[#boost-urls-url-remove_scheme]

= Function url::remove_scheme

pass:v,q[Remove the scheme]


== Synopsis

Declared in header `</boost/url/url.hpp#L413[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_scheme();
----

== Description

pass:v,q[This function removes the scheme if it] pass:v,q[is present.]

=== Example
[,cpp]
----
assert( url("http://www.example.com/index.htm" ).remove_scheme().buffer() == "//www.example.com/index.htm" );
----

=== Postconditions
[,cpp]
----
this->has_scheme() == false && this->scheme_id() == scheme::none
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

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

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[            3.1. Scheme (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-set_encoded_authority]

= Function url::set_encoded_authority

pass:v,q[Set the authority]


== Synopsis

Declared in header `</boost/url/url.hpp#L416[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_authority(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the authority] pass:v,q[to the specified string.] pass:v,q[The string may contain percent-escapes.]

=== Example
[,cpp]
----
assert( url().set_encoded_authority( "My%20Computer" ).has_authority() );
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = *( unreserved / pct-encoded / sub-delims / ":" )
host          = IP-literal / IPv4address / reg-name
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[            3.2. Authority (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-remove_authority]

= Function url::remove_authority

pass:v,q[Remove the authority]


== Synopsis

Declared in header `</boost/url/url.hpp#L418[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_authority();
----

== Description

pass:v,q[This function removes the authority,] pass:v,q[which includes the userinfo, host, and]
pass:v,q[a port if present.]

=== Example
[,cpp]
----
assert( url( "http://example.com/echo.cgi" ).remove_authority().buffer() == "http:/echo.cgi" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == false && this->has_userinfo() == false && this->has_port() == false
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = *( unreserved / pct-encoded / sub-delims / ":" )
host          = IP-literal / IPv4address / reg-name
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[            3.2. Authority (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-set_userinfo]

= Function url::set_userinfo

pass:v,q[Set the userinfo]


== Synopsis

Declared in header `</boost/url/url.hpp#L421[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_userinfo(string_view s);
----

== Description

pass:v,q[The userinfo is set to the given string,] pass:v,q[which may contain percent-escapes.]
pass:v,q[Any special or reserved characters in the]
pass:v,q[string are automatically percent-encoded.]
pass:v,q[The effects on the user and password]
pass:v,q[depend on the presence of a colon (':')]
pass:v,q[in the string:]

* pass:v,q[If an unescaped colon exists, the]
pass:v,q[characters up to the colon become]
pass:v,q[the user and the rest of the characters]
pass:v,q[after the colon become the password.]
pass:v,q[In this case]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns]
pass:v,q[true. Otherwise,]

* pass:v,q[If there is no colon, the user is]
pass:v,q[set to the string. The function]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns false.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_userinfo( "user:pass" ).encoded_user() == "user" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_userinfo]

= Function url::set_encoded_userinfo

pass:v,q[Set the userinfo.]


== Synopsis

Declared in header `</boost/url/url.hpp#L423[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_userinfo(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[The userinfo is set to the given string,] pass:v,q[which may contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The effects on the user and password]
pass:v,q[depend on the presence of a colon (':')]
pass:v,q[in the string:]

* pass:v,q[If an unescaped colon exists, the]
pass:v,q[characters up to the colon become]
pass:v,q[the user and the rest of the characters]
pass:v,q[after the colon become the password.]
pass:v,q[In this case]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns]
pass:v,q[true. Otherwise,]

* pass:v,q[If there is no colon, the user is]
pass:v,q[set to the string. The function]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns false.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_userinfo( "john%20doe" ).user() == "john doe" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-remove_userinfo]

= Function url::remove_userinfo

pass:v,q[Remove the userinfo]


== Synopsis

Declared in header `</boost/url/url.hpp#L425[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_userinfo() noexcept;
----

== Description

pass:v,q[This function removes the userinfo if] pass:v,q[present, without removing any authority.]

=== Example
[,cpp]
----
assert( url( "http://user@example.com" ).remove_userinfo().has_userinfo() == false );
----

=== Postconditions
[,cpp]
----
this->has_userinfo() == false && this->encoded_userinfo().empty == true
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-set_user]

= Function url::set_user

pass:v,q[Set the user]


== Synopsis

Declared in header `</boost/url/url.hpp#L427[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_user(string_view s);
----

== Description

pass:v,q[This function sets the user part of the] pass:v,q[userinfo to the string.]
pass:v,q[Any special or reserved characters in the]
pass:v,q[string are automatically percent-encoded.]

=== Example
[,cpp]
----
assert( url().set_user("john doe").encoded_userinfo() == "john%20doe" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_userinfo() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_user]

= Function url::set_encoded_user

pass:v,q[Set the user]


== Synopsis

Declared in header `</boost/url/url.hpp#L429[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_user(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the user part of the] pass:v,q[userinfo the the string, which may]
pass:v,q[contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url().set_encoded_user("john%20doe").userinfo() == "john doe" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_userinfo() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-set_password]

= Function url::set_password

pass:v,q[Set the password.]


== Synopsis

Declared in header `</boost/url/url.hpp#L431[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_password(string_view s);
----

== Description

pass:v,q[This function sets the password in] pass:v,q[the userinfo to the string.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url("http://user@example.com").set_password( "pass" ).encoded_userinfo() == "user:pass" );
----

=== Postconditions
[,cpp]
----
this->has_password() == true && this->password() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_password]

= Function url::set_encoded_password

pass:v,q[Set the password.]


== Synopsis

Declared in header `</boost/url/url.hpp#L433[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_password(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the password in] pass:v,q[the userinfo to the string, which]
pass:v,q[may contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url("http://user@example.com").set_encoded_password( "pass" ).encoded_userinfo() == "user:pass" );
----

=== Postconditions
[,cpp]
----
this->has_password() == true
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-remove_password]

= Function url::remove_password

pass:v,q[Remove the password]


== Synopsis

Declared in header `</boost/url/url.hpp#L435[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_password() noexcept;
----

== Description

pass:v,q[This function removes the password from] pass:v,q[the userinfo if a password exists. If]
pass:v,q[there is no userinfo or no authority,]
pass:v,q[the call has no effect.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://user:pass@example.com" ).remove_password().authority().buffer() == "user@example.com" );
----

=== Postconditions
[,cpp]
----
this->has_password() == false && this->encoded_password().empty() == true
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-set_host]

= Function url::set_host

pass:v,q[Set the host]


== Synopsis

Declared in header `</boost/url/url.hpp#L438[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_host(string_view s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address]
pass:v,q[enclosed in square brackets, then the]
pass:v,q[host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture]
pass:v,q[address enclosed in square brackets, then]
pass:v,q[the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_host]

= Function url::set_encoded_host

pass:v,q[Set the host]


== Synopsis

Declared in header `</boost/url/url.hpp#L440[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_host(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address]
pass:v,q[enclosed in square brackets, then the]
pass:v,q[host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture]
pass:v,q[address enclosed in square brackets, then]
pass:v,q[the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string. This string can contain percent]
pass:v,q[escapes, or can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-set_host_address]

= Function url::set_host_address

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url.hpp#L442[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_host_address(string_view s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host_address( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255

IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal

IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_host_address]

= Function url::set_encoded_host_address

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url.hpp#L444[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_host_address(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string. This string can contain percent]
pass:v,q[escapes, or can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255

IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal

IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-set_host_ipv4]

= Function url::set_host_ipv4

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url.hpp#L446[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_host_ipv4(const xref:boost-urls-ipv4_address[ipv4_address]& addr);
----

== Description

pass:v,q[The host is set to the specified IPv4] pass:v,q[address.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

=== Example
[,cpp]
----
assert( url("http://www.example.com").set_host_ipv4( ipv4_address( "127.0.0.1" ) ).buffer() == "http://127.0.0.1" );
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv4_address() == addr && this->host_type() == host_type::ipv4
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *addr*
| ``

|===




[#boost-urls-url-set_host_ipv6]

= Function url::set_host_ipv6

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url.hpp#L448[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_host_ipv6(const xref:boost-urls-ipv6_address[ipv6_address]& addr);
----

== Description

pass:v,q[The host is set to the specified IPv6] pass:v,q[address.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

=== Example
[,cpp]
----
assert( url().set_host_ipv6( ipv6_address( "1::6:c0a8:1" ) ).authority().buffer() == "[1::6:c0a8:1]" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::ipv6
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *addr*
| ``

|===




[#boost-urls-url-set_host_ipvfuture]

= Function url::set_host_ipvfuture

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/url.hpp#L450[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_host_ipvfuture(string_view s);
----

== Description

pass:v,q[The host is set to the specified IPvFuture] pass:v,q[string.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

=== Example
[,cpp]
----
assert( url().set_host_ipvfuture( "v42.bis" ).buffer() == "//[v42.bis]" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipvfuture) == s && this->host_type() == host_type::ipvfuture
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_host_name]

= Function url::set_host_name

pass:v,q[Set the host to a name]


== Synopsis

Declared in header `</boost/url/url.hpp#L452[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_host_name(string_view s);
----

== Description

pass:v,q[The host is set to the specified string,] pass:v,q[which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm").set_host_name( "localhost" ).host_address() == "localhost" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::name
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_host_name]

= Function url::set_encoded_host_name

pass:v,q[Set the host to a name]


== Synopsis

Declared in header `</boost/url/url.hpp#L454[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_host_name(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[The host is set to the specified string,] pass:v,q[which may contain percent-escapes and]
pass:v,q[can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm").set_encoded_host_name( "localhost" ).host_address() == "localhost" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::name
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-set_port_number]

= Function url::set_port_number

pass:v,q[Set the port]


== Synopsis

Declared in header `</boost/url/url.hpp#L456[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_port_number(uint16_t n);
----

== Description

pass:v,q[The port is set to the specified integer.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_port_number( 8080 ).authority().buffer() == "www.example.com:8080" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_port() == true && this->port_number() == n
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *n*
| `uint16_t`

|===




[#boost-urls-url-set_port]

= Function url::set_port

pass:v,q[Set the port]


== Synopsis

Declared in header `</boost/url/url.hpp#L458[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_port(string_view s);
----

== Description

pass:v,q[This port is set to the string, which] pass:v,q[must contain only digits or be empty.]
pass:v,q[An empty port string is distinct from]
pass:v,q[having no port.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_port( "8080" ).authority().buffer() == "www.example.com:8080" );
----

=== Postconditions
[,cpp]
----
this->has_port() == true && this->port_number() == n && this->port() == std::to_string(n)
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-remove_port]

= Function url::remove_port

pass:v,q[Remove the port]


== Synopsis

Declared in header `</boost/url/url.hpp#L460[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_port() noexcept;
----

== Description

pass:v,q[If a port exists, it is removed. The rest] pass:v,q[of the authority is unchanged.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com:80" ).remove_port().authority().buffer() == "www.example.com" );
----

=== Postconditions
[,cpp]
----
this->has_port() == false && this->port_number() == 0 && this->port() == ""
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-set_path]

= Function url::set_path

pass:v,q[Set the path.]


== Synopsis

Declared in header `</boost/url/url.hpp#L465[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_path(string_view s);
----

== Description

pass:v,q[This function sets the path to the] pass:v,q[string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
[NOTE]
pass:v,q[The library may adjust the final result]
pass:v,q[to ensure that no other parts of the url]
pass:v,q[is semantically affected.]
[NOTE]
pass:v,q[This function does not encode '/' chars, which]
pass:v,q[are unreserved for paths but reserved for]
pass:v,q[path segments. If a path segment should include]
pass:v,q[encoded '/'s to differentiate it from path separators,]
pass:v,q[the functions]
xref:boost-urls-url_base-set_encoded_path[set_encoded_path]
pass:v,q[or]
xref:boost-urls-url_base-segments-04[segments]
pass:v,q[should be used instead.]

=== Example
[,cpp]
----
url u( "http://www.example.com" );

u.set_path( "path/to/file.txt" );

assert( u.path() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_path]

= Function url::set_encoded_path

pass:v,q[Set the path.]


== Synopsis

Declared in header `</boost/url/url.hpp#L467[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_path(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the path to the] pass:v,q[string, which may contain percent-escapes]
pass:v,q[and can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
[NOTE]
pass:v,q[The library may adjust the final result]
pass:v,q[to ensure that no other parts of the url]
pass:v,q[is semantically affected.]

=== Example
[,cpp]
----
url u( "http://www.example.com" );

u.set_encoded_path( "path/to/file.txt" );

assert( u.encoded_path() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-set_query]

= Function url::set_query

pass:v,q[Set the query]


== Synopsis

Declared in header `</boost/url/url.hpp#L470[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_query(string_view s);
----

== Description

pass:v,q[This sets the query to the string, which] pass:v,q[can be empty.] pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_query( "id=42" ).query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true && this->query() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_query]

= Function url::set_encoded_query

pass:v,q[Set the query]


== Synopsis

Declared in header `</boost/url/url.hpp#L472[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_query(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This sets the query to the string, which] pass:v,q[may contain percent-escapes and can be]
pass:v,q[empty.]
pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_query( "id=42" ).encoded_query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true && this->query() == decode_view( s );
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-set_params]

= Function url::set_params

pass:v,q[Set the query params]


== Synopsis

Declared in header `</boost/url/url.hpp#L474[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_params(initializer_list<xref:boost-urls-param_view[param_view]> ps);
----

== Description

pass:v,q[This sets the query params to the list] pass:v,q[of param_view, which can be empty.]
pass:v,q[An empty list of params is distinct from]
pass:v,q[having no params.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_params( {"id", "42"} ).query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Complexity
pass:v,q[Linear.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *ps*
| `initializer_list`

|===




[#boost-urls-url-set_encoded_params]

= Function url::set_encoded_params

pass:v,q[Set the query params]


== Synopsis

Declared in header `</boost/url/url.hpp#L476[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_params(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> ps);
----

== Description

pass:v,q[This sets the query params to the elements] pass:v,q[in the list, which may contain]
pass:v,q[percent-escapes and can be empty.]
pass:v,q[An empty list of params is distinct from]
pass:v,q[having no query.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_params( {"id", "42"} ).encoded_query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true
----

=== Complexity
pass:v,q[Linear.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *ps*
| `initializer_list`

|===




[#boost-urls-url-remove_query]

= Function url::remove_query

pass:v,q[Remove the query]


== Synopsis

Declared in header `</boost/url/url.hpp#L478[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_query() noexcept;
----

== Description

pass:v,q[If a query is present, it is removed.] pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com?id=42" ).remove_query().buffer() == "http://www.example.com" );
----

=== Postconditions
[,cpp]
----
this->has_query() == false && this->params().empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 





[#boost-urls-url-remove_fragment]

= Function url::remove_fragment

pass:v,q[Remove the fragment]


== Synopsis

Declared in header `</boost/url/url.hpp#L481[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_fragment() noexcept;
----

== Description

pass:v,q[This function removes the fragment.] pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]

=== Example
[,cpp]
----
assert( url( "?first=john&last=doe#anchor" ).remove_fragment().buffer() == "?first=john&last=doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == false && this->encoded_fragment() == ""
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 





[#boost-urls-url-set_fragment]

= Function url::set_fragment

pass:v,q[Set the fragment.]


== Synopsis

Declared in header `</boost/url/url.hpp#L483[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_fragment(string_view s);
----

== Description

pass:v,q[This function sets the fragment to the] pass:v,q[specified string, which may be empty.]
pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url("?first=john&last=doe" ).set_encoded_fragment( "john doe" ).encoded_fragment() == "john%20doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == true && this->fragment() == s
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-set_encoded_fragment]

= Function url::set_encoded_fragment

pass:v,q[Set the fragment.]


== Synopsis

Declared in header `</boost/url/url.hpp#L485[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
set_encoded_fragment(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the fragment to the] pass:v,q[specified string, which may contain]
pass:v,q[percent-escapes and which may be empty.]
pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url("?first=john&last=doe" ).set_encoded_fragment( "john%2Ddoe" ).fragment() == "john-doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == true && this->fragment() == decode_view( s )
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-url-remove_origin]

= Function url::remove_origin

pass:v,q[Remove the origin component]


== Synopsis

Declared in header `</boost/url/url.hpp#L488[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
remove_origin();
----

== Description

pass:v,q[This function removes the origin, which] pass:v,q[consists of the scheme and authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm" ).remove_origin().buffer() == "/index.htm" );
----

=== Postconditions
[,cpp]
----
this->scheme_id() == scheme::none && this->has_authority() == false
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-url-normalize]

= Function url::normalize

pass:v,q[Normalize the URL components]


== Synopsis

Declared in header `</boost/url/url.hpp#L491[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
normalize();
----

== Description

pass:v,q[Applies Syntax-based normalization to] pass:v,q[all components of the URL.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-normalize_scheme]

= Function url::normalize_scheme

pass:v,q[Normalize the URL scheme]


== Synopsis

Declared in header `</boost/url/url.hpp#L493[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
normalize_scheme();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL scheme.]
pass:v,q[The scheme is normalized to lowercase.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-normalize_authority]

= Function url::normalize_authority

pass:v,q[Normalize the URL authority]


== Synopsis

Declared in header `</boost/url/url.hpp#L495[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
normalize_authority();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL authority.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-normalize_path]

= Function url::normalize_path

pass:v,q[Normalize the URL path]


== Synopsis

Declared in header `</boost/url/url.hpp#L497[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
normalize_path();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL path.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded. Redundant]
pass:v,q[path-segments are removed.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-normalize_query]

= Function url::normalize_query

pass:v,q[Normalize the URL query]


== Synopsis

Declared in header `</boost/url/url.hpp#L499[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
normalize_query();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL query.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-url-normalize_fragment]

= Function url::normalize_fragment

pass:v,q[Normalize the URL fragment]


== Synopsis

Declared in header `</boost/url/url.hpp#L501[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
normalize_fragment();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL fragment.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-swap]

= Function swap

pass:v,q[Swap]


== Synopsis

Declared in header `</boost/url/url.hpp#L396[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
swap(
    xref:boost-urls-url[url]& v0,
    xref:boost-urls-url[url]& v1) noexcept;
----

== Description

pass:v,q[Exchanges the contents of `v0` with another `v1`.] pass:v,q[All views, iterators and references remain]
pass:v,q[valid.]
pass:v,q[If `]
pass:v,q[&v]
pass:v,q[0 ==]
pass:v,q[&v]
pass:v,q[1`, this function call has no effect.]

=== Example
[,cpp]
----
url u1( "https://www.example.com" );
url u2( "https://www.boost.org" );
std::swap(u1, u2);
assert(u1 == "https://www.boost.org" );
assert(u2 == "https://www.example.com" );
----

=== Effects
[,cpp]
----
v0.swap( v1 );
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *v0*
| ``

| *v1*
| ``

|===




[#boost-urls-ipv4_address_rule_t]

= Class ipv4_address_rule_t



== Synopsis

Declared in header `</boost/url/rfc/ipv4_address_rule.hpp#L58[boost/url/rfc/ipv4_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct ipv4_address_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv4_address_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv4_address_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-ipv4_address_rule_t-value_type]

= ipv4_address_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/ipv4_address_rule.hpp#L60[boost/url/rfc/ipv4_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-ipv4_address[ipv4_address];
----


[#boost-urls-ipv4_address_rule_t-parse]

= Function ipv4_address_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/ipv4_address_rule.hpp#L64[boost/url/rfc/ipv4_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-ipv4_address[ipv4_address]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-ipv4_address_rule]

= ipv4_address_rule



== Synopsis

Declared in header `</boost/url/rfc/ipv4_address_rule.hpp#L72[boost/url/rfc/ipv4_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-ipv4_address_rule_t[ipv4_address_rule_t] ipv4_address_rule;
----


[#boost-urls-ipv6_address_rule_t]

= Class ipv6_address_rule_t



== Synopsis

Declared in header `</boost/url/rfc/ipv6_address_rule.hpp#L66[boost/url/rfc/ipv6_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct ipv6_address_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv6_address_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-ipv6_address_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-ipv6_address_rule_t-value_type]

= ipv6_address_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/ipv6_address_rule.hpp#L68[boost/url/rfc/ipv6_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-ipv6_address[ipv6_address];
----


[#boost-urls-ipv6_address_rule_t-parse]

= Function ipv6_address_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/ipv6_address_rule.hpp#L72[boost/url/rfc/ipv6_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-ipv6_address[ipv6_address]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-ipv6_address_rule]

= ipv6_address_rule



== Synopsis

Declared in header `</boost/url/rfc/ipv6_address_rule.hpp#L80[boost/url/rfc/ipv6_address_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-ipv6_address_rule_t[ipv6_address_rule_t] ipv6_address_rule;
----


[#boost-urls-parse_absolute_uri]

= Function parse_absolute_uri

pass:v,q[Return a reference to a parsed URL string]


== Synopsis

Declared in header `</boost/url/parse.hpp#L65[boost/url/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-url_view[url_view]>
parse_absolute_uri(string_view s);
----

== Description

pass:v,q[This function parses a string according] pass:v,q[to the grammar below and returns a view]
pass:v,q[referencing the passed string upon success,]
pass:v,q[else returns an error.]
pass:v,q[Ownership of the string is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the lifetime of the character buffer extends]
pass:v,q[until the view is no longer being accessed.]

=== Example
[,cpp]
----
system::result< url_view > rv = parse_absolute_uri( "http://example.com/index.htm?id=1" );
----

=== BNF
[,cpp]
----
absolute-URI    = scheme ":" hier-part [ "?" query ]

hier-part       = "//" authority path-abempty
                / path-absolute
                / path-rootless
                / path-empty
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.3[4.3. Absolute URI (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-parse_origin_form]

= Function parse_origin_form

pass:v,q[Return a reference to a parsed URL string]


== Synopsis

Declared in header `</boost/url/parse.hpp#L112[boost/url/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-url_view[url_view]>
parse_origin_form(string_view s);
----

== Description

pass:v,q[This function parses a string according] pass:v,q[to the grammar below and returns a view]
pass:v,q[referencing the passed string upon success,]
pass:v,q[else returns an error.]
pass:v,q[Ownership of the string is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the lifetime of the character buffer extends]
pass:v,q[until the view is no longer being accessed.]

=== Example
[,cpp]
----
system::result< url_view > = parse_origin_form( "/index.htm?layout=mobile" );
----

=== BNF
[,cpp]
----
origin-form    = absolute-path [ "?" query ]

absolute-path = 1*( "/" segment )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc7230#section-5.3.1[5.3.1.  origin-form (rfc7230)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-parse_relative_ref]

= Function parse_relative_ref

pass:v,q[Return a reference to a parsed URL string]


== Synopsis

Declared in header `</boost/url/parse.hpp#L165[boost/url/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-url_view[url_view]>
parse_relative_ref(string_view s);
----

== Description

pass:v,q[This function parses a string according] pass:v,q[to the grammar below and returns a view]
pass:v,q[referencing the passed string upon success,]
pass:v,q[else returns an error.]
pass:v,q[Ownership of the string is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the lifetime of the character buffer extends]
pass:v,q[until the view is no longer being accessed.]

=== Example
[,cpp]
----
system::result< url_view > = parse_relative_ref( "images/dot.gif?v=hide#a" );
----

=== BNF
[,cpp]
----
relative-ref  = relative-part [ "?" query ] [ "#" fragment ]

relative-part = "//" authority path-abempty
              / path-absolute
              / path-noscheme
              / path-abempty
              / path-empty
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.2[4.2. Relative Reference (rfc3986)]

* link:https://www.rfc-editor.org/errata/eid5428[Errata ID: 5428 (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-parse_uri]

= Function parse_uri

pass:v,q[Return a reference to a parsed URL string]


== Synopsis

Declared in header `</boost/url/parse.hpp#L215[boost/url/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-url_view[url_view]>
parse_uri(string_view s);
----

== Description

pass:v,q[This function parses a string according] pass:v,q[to the grammar below and returns a view]
pass:v,q[referencing the passed string upon success,]
pass:v,q[else returns an error.]
pass:v,q[Ownership of the string is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the lifetime of the character buffer extends]
pass:v,q[until the view is no longer being accessed.]

=== Example
[,cpp]
----
system::result< url_view > = parse_uri( "https://www.example.com/index.htm?id=guest#s1" );
----

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

hier-part     = "//" authority path-abempty
              / path-absolute
              / path-rootless
              / path-empty
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3[3. Syntax Components (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-parse_uri_reference]

= Function parse_uri_reference

pass:v,q[Return a reference to a parsed URL string]


== Synopsis

Declared in header `</boost/url/parse.hpp#L277[boost/url/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-url_view[url_view]>
parse_uri_reference(string_view s);
----

== Description

pass:v,q[This function parses a string according] pass:v,q[to the grammar below and returns a view]
pass:v,q[referencing the passed string upon success,]
pass:v,q[else returns an error.]
pass:v,q[Ownership of the string is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the lifetime of the character buffer extends]
pass:v,q[until the view is no longer being accessed.]

=== Example
[,cpp]
----
system::result< url_view > = parse_uri_reference( "ws://echo.example.com/?name=boost#demo" );
----

=== BNF
[,cpp]
----
URI-reference = URI / relative-ref

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

relative-ref  = relative-part [ "?" query ] [ "#" fragment ]

hier-part     = "//" authority path-abempty
              / path-absolute
              / path-rootless
              / path-empty

relative-part = "//" authority path-abempty
              / path-absolute
              / path-noscheme
              / path-abempty
              / path-empty
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.1[4.1. URI Reference (rfc3986)]

* link:https://www.rfc-editor.org/errata/eid5428[Errata ID: 5428 (rfc3986)]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-absolute_uri_rule_t]

= Class absolute_uri_rule_t



== Synopsis

Declared in header `</boost/url/rfc/absolute_uri_rule.hpp#L55[boost/url/rfc/absolute_uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct absolute_uri_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-absolute_uri_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-absolute_uri_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-absolute_uri_rule_t-value_type]

= absolute_uri_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/absolute_uri_rule.hpp#L57[boost/url/rfc/absolute_uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-url_view[url_view];
----


[#boost-urls-absolute_uri_rule_t-parse]

= Function absolute_uri_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/absolute_uri_rule.hpp#L60[boost/url/rfc/absolute_uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-absolute_uri_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-absolute_uri_rule]

= absolute_uri_rule



== Synopsis

Declared in header `</boost/url/rfc/absolute_uri_rule.hpp#L68[boost/url/rfc/absolute_uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-absolute_uri_rule_t[absolute_uri_rule_t] absolute_uri_rule;
----


[#boost-urls-relative_ref_rule_t]

= Class relative_ref_rule_t



== Synopsis

Declared in header `</boost/url/rfc/relative_ref_rule.hpp#L50[boost/url/rfc/relative_ref_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct relative_ref_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-relative_ref_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-relative_ref_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-relative_ref_rule_t-value_type]

= relative_ref_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/relative_ref_rule.hpp#L52[boost/url/rfc/relative_ref_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-url_view[url_view];
----


[#boost-urls-relative_ref_rule_t-parse]

= Function relative_ref_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/relative_ref_rule.hpp#L55[boost/url/rfc/relative_ref_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-relative_ref_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-relative_ref_rule]

= relative_ref_rule



== Synopsis

Declared in header `</boost/url/rfc/relative_ref_rule.hpp#L63[boost/url/rfc/relative_ref_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-relative_ref_rule_t[relative_ref_rule_t] relative_ref_rule;
----


[#boost-urls-uri_rule_t]

= Class uri_rule_t



== Synopsis

Declared in header `</boost/url/rfc/uri_rule.hpp#L50[boost/url/rfc/uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct uri_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-uri_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-uri_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-uri_rule_t-value_type]

= uri_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/uri_rule.hpp#L52[boost/url/rfc/uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-url_view[url_view];
----


[#boost-urls-uri_rule_t-parse]

= Function uri_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/uri_rule.hpp#L55[boost/url/rfc/uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-uri_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* const end) const noexcept;
----


[#boost-urls-uri_rule]

= uri_rule



== Synopsis

Declared in header `</boost/url/rfc/uri_rule.hpp#L63[boost/url/rfc/uri_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-uri_rule_t[uri_rule_t] uri_rule;
----


[#boost-urls-uri_reference_rule_t]

= Class uri_reference_rule_t



== Synopsis

Declared in header `</boost/url/rfc/uri_reference_rule.hpp#L53[boost/url/rfc/uri_reference_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct uri_reference_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-uri_reference_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-uri_reference_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-uri_reference_rule_t-value_type]

= uri_reference_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/uri_reference_rule.hpp#L55[boost/url/rfc/uri_reference_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-url_view[url_view];
----


[#boost-urls-uri_reference_rule_t-parse]

= Function uri_reference_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/uri_reference_rule.hpp#L58[boost/url/rfc/uri_reference_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-uri_reference_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-uri_reference_rule]

= uri_reference_rule



== Synopsis

Declared in header `</boost/url/rfc/uri_reference_rule.hpp#L66[boost/url/rfc/uri_reference_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-uri_reference_rule_t[uri_reference_rule_t] uri_reference_rule;
----


[#boost-urls-origin_form_rule_t]

= Class origin_form_rule_t



== Synopsis

Declared in header `</boost/url/rfc/origin_form_rule.hpp#L53[boost/url/rfc/origin_form_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct origin_form_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-origin_form_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-origin_form_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-origin_form_rule_t-value_type]

= origin_form_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/origin_form_rule.hpp#L55[boost/url/rfc/origin_form_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-url_view[url_view];
----


[#boost-urls-origin_form_rule_t-parse]

= Function origin_form_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/origin_form_rule.hpp#L59[boost/url/rfc/origin_form_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-origin_form_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-origin_form_rule]

= origin_form_rule



== Synopsis

Declared in header `</boost/url/rfc/origin_form_rule.hpp#L66[boost/url/rfc/origin_form_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-origin_form_rule_t[origin_form_rule_t] origin_form_rule;
----


[#boost-urls-query_rule_t]

= Class query_rule_t



== Synopsis

Declared in header `</boost/url/rfc/query_rule.hpp#L60[boost/url/rfc/query_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct query_rule_t;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-urls-query_rule_t-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-query_rule_t-parse[`pass:v[parse]`] |

|===



[#boost-urls-query_rule_t-value_type]

= query_rule_t::value_type



== Synopsis

Declared in header `</boost/url/rfc/query_rule.hpp#L62[boost/url/rfc/query_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using value_type = xref:boost-urls-params_encoded_view[params_encoded_view];
----


[#boost-urls-query_rule_t-parse]

= Function query_rule_t::parse



== Synopsis

Declared in header `</boost/url/rfc/query_rule.hpp#L65[boost/url/rfc/query_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
result<xref:boost-urls-query_rule_t-value_type[value_type]>
parse(
    const char*& it,
    const char* end) const noexcept;
----


[#boost-urls-query_rule]

= query_rule



== Synopsis

Declared in header `</boost/url/rfc/query_rule.hpp#L72[boost/url/rfc/query_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
const xref:boost-urls-query_rule_t[query_rule_t] query_rule;
----


[#boost-urls-static_url]

= Class static_url

pass:v,q[A modifiable container for a URL.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L107[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<size_t Capacity>
class static_url
    : public xref:boost-urls-static_url_base[static_url_base];
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-authority[`pass:v[authority]`] |
pass:v,q[Return the authority]

|xref:boost-urls-url_view_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the url string]

|xref:boost-urls-url_base-c_str[`pass:v[c_str]`] |
pass:v,q[Return the url as a null-terminated string]

|xref:boost-urls-url_base-capacity[`pass:v[capacity]`] |
pass:v,q[Return the number of characters that can be stored without reallocating]

|xref:boost-urls-url_base-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents while preserving the capacity]

|xref:boost-urls-url_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing this with another url]

|xref:boost-urls-url_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the url's character buffer]

|xref:boost-urls-url_view_base-digest[`pass:v[digest]`] |

|xref:boost-urls-url_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the url is empty]

|xref:boost-urls-url_view_base-encoded_authority[`pass:v[encoded_authority]`] |
pass:v,q[Return the authority.]

|xref:boost-urls-url_view_base-encoded_fragment[`pass:v[encoded_fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-encoded_host[`pass:v[encoded_host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_address[`pass:v[encoded_host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_and_port[`pass:v[encoded_host_and_port]`] |
pass:v,q[Return the host and port]

|xref:boost-urls-url_view_base-encoded_host_name[`pass:v[encoded_host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-encoded_origin[`pass:v[encoded_origin]`] |
pass:v,q[Return the origin]

|xref:boost-urls-url_view_base-encoded_params[`pass:v[encoded_params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-encoded_password[`pass:v[encoded_password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-encoded_path[`pass:v[encoded_path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-encoded_query[`pass:v[encoded_query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-encoded_resource[`pass:v[encoded_resource]`] |
pass:v,q[Return the resource]

|xref:boost-urls-url_view_base-encoded_segments[`pass:v[encoded_segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-encoded_target[`pass:v[encoded_target]`] |
pass:v,q[Return the target]

|xref:boost-urls-url_view_base-encoded_user[`pass:v[encoded_user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-encoded_userinfo[`pass:v[encoded_userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-encoded_zone_id[`pass:v[encoded_zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url_view_base-fragment[`pass:v[fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-has_authority[`pass:v[has_authority]`] |
pass:v,q[Return true if an authority is present]

|xref:boost-urls-url_view_base-has_fragment[`pass:v[has_fragment]`] |
pass:v,q[Return true if a fragment is present]

|xref:boost-urls-url_view_base-has_password[`pass:v[has_password]`] |
pass:v,q[Return true if a password is present]

|xref:boost-urls-url_view_base-has_port[`pass:v[has_port]`] |
pass:v,q[Return true if a port is present]

|xref:boost-urls-url_view_base-has_query[`pass:v[has_query]`] |
pass:v,q[Return true if a query is present]

|xref:boost-urls-url_view_base-has_scheme[`pass:v[has_scheme]`] |
pass:v,q[Return true a scheme is present]

|xref:boost-urls-url_view_base-has_userinfo[`pass:v[has_userinfo]`] |
pass:v,q[Return true if a userinfo is present]

|xref:boost-urls-url_view_base-host[`pass:v[host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_address[`pass:v[host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_ipv4_address[`pass:v[host_ipv4_address]`] |
pass:v,q[Return the host IPv4 address]

|xref:boost-urls-url_view_base-host_ipv6_address[`pass:v[host_ipv6_address]`] |
pass:v,q[Return the host IPv6 address]

|xref:boost-urls-url_view_base-host_ipvfuture[`pass:v[host_ipvfuture]`] |
pass:v,q[Return the host IPvFuture address]

|xref:boost-urls-url_view_base-host_name[`pass:v[host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-host_type[`pass:v[host_type]`] |
pass:v,q[Return the host type]

|xref:boost-urls-url_view_base-is_path_absolute[`pass:v[is_path_absolute]`] |
pass:v,q[Return true if the path is absolute]

|xref:boost-urls-url_base-normalize[`pass:v[normalize]`] |
pass:v,q[Normalize the URL components]

|xref:boost-urls-url_base-normalize_authority[`pass:v[normalize_authority]`] |
pass:v,q[Normalize the URL authority]

|xref:boost-urls-url_base-normalize_fragment[`pass:v[normalize_fragment]`] |
pass:v,q[Normalize the URL fragment]

|xref:boost-urls-url_base-normalize_path[`pass:v[normalize_path]`] |
pass:v,q[Normalize the URL path]

|xref:boost-urls-url_base-normalize_query[`pass:v[normalize_query]`] |
pass:v,q[Normalize the URL query]

|xref:boost-urls-url_base-normalize_scheme[`pass:v[normalize_scheme]`] |
pass:v,q[Normalize the URL scheme]

|xref:boost-urls-url_view_base-2conversion[`pass:v[operator string_view]`] |
pass:v,q[Return the URL as a core::string_view]

|xref:boost-urls-static_url-operator_assign[`pass:v[operator=]`] |
pass:v,q[Assignment]

|xref:boost-urls-url_view_base-params[`pass:v[params]`] |
pass:v,q[Return the query as a container of parameters]

xref:boost-urls-url_view_base-params-05[url_view_base::params]

|xref:boost-urls-url_view_base-password[`pass:v[password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-path[`pass:v[path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-persist[`pass:v[persist]`] |
pass:v,q[Return a shared, persistent copy of the url]

|xref:boost-urls-url_view_base-port[`pass:v[port]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-port_number[`pass:v[port_number]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-query[`pass:v[query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_base-remove_authority[`pass:v[remove_authority]`] |
pass:v,q[Remove the authority]

|xref:boost-urls-url_base-remove_fragment[`pass:v[remove_fragment]`] |
pass:v,q[Remove the fragment]

|xref:boost-urls-url_base-remove_origin[`pass:v[remove_origin]`] |
pass:v,q[Remove the origin component]

|xref:boost-urls-url_base-remove_password[`pass:v[remove_password]`] |
pass:v,q[Remove the password]

|xref:boost-urls-url_base-remove_port[`pass:v[remove_port]`] |
pass:v,q[Remove the port]

|xref:boost-urls-url_base-remove_query[`pass:v[remove_query]`] |
pass:v,q[Remove the query]

|xref:boost-urls-url_base-remove_scheme[`pass:v[remove_scheme]`] |
pass:v,q[Remove the scheme]

|xref:boost-urls-url_base-remove_userinfo[`pass:v[remove_userinfo]`] |
pass:v,q[Remove the userinfo]

|xref:boost-urls-url_base-reserve[`pass:v[reserve]`] |
pass:v,q[Adjust the capacity without changing the size]

|xref:boost-urls-url_base-resolve[`pass:v[resolve]`] |
pass:v,q[Resolve a URL reference against this base URL]

|xref:boost-urls-url_view_base-scheme[`pass:v[scheme]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-scheme_id[`pass:v[scheme_id]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-segments[`pass:v[segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_base-set_encoded_authority[`pass:v[set_encoded_authority]`] |
pass:v,q[Set the authority]

|xref:boost-urls-url_base-set_encoded_fragment[`pass:v[set_encoded_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_encoded_host[`pass:v[set_encoded_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_encoded_host_address[`pass:v[set_encoded_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_encoded_host_name[`pass:v[set_encoded_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_encoded_params[`pass:v[set_encoded_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_encoded_password[`pass:v[set_encoded_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_encoded_path[`pass:v[set_encoded_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_encoded_query[`pass:v[set_encoded_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_encoded_user[`pass:v[set_encoded_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_encoded_userinfo[`pass:v[set_encoded_userinfo]`] |
pass:v,q[Set the userinfo.]

|xref:boost-urls-url_base-set_fragment[`pass:v[set_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_host[`pass:v[set_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_host_address[`pass:v[set_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv4[`pass:v[set_host_ipv4]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv6[`pass:v[set_host_ipv6]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipvfuture[`pass:v[set_host_ipvfuture]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_name[`pass:v[set_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_params[`pass:v[set_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_password[`pass:v[set_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_path[`pass:v[set_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_path_absolute[`pass:v[set_path_absolute]`] |
pass:v,q[Set if the path is absolute]

|xref:boost-urls-url_base-set_port[`pass:v[set_port]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_port_number[`pass:v[set_port_number]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_query[`pass:v[set_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_scheme[`pass:v[set_scheme]`] |
pass:v,q[Set the scheme]

|xref:boost-urls-url_base-set_scheme_id[`pass:v[set_scheme_id]`] |
xref:boost-urls-url_base-set_scheme_id[url_base::set_scheme_id]

|xref:boost-urls-url_base-set_user[`pass:v[set_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_userinfo[`pass:v[set_userinfo]`] |
pass:v,q[Set the userinfo]

|xref:boost-urls-url_view_base-size[`pass:v[size]`] |
pass:v,q[Return the number of characters in the url]

|xref:boost-urls-static_url-2constructor[`pass:v[static_url]`] |
pass:v,q[Constructor]

|xref:boost-urls-url_view_base-user[`pass:v[user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-userinfo[`pass:v[userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-zone_id[`pass:v[zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-static_url-2destructor[`pass:v[~static_url]`] |
pass:v,q[Destructor]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-8friend-02[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-05[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-03[`pass:v[operator<<]`] |

|xref:boost-urls-url_view_base-8friend-04[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-07c[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-073[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-06[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_base-8friend[`pass:v[resolve]`] |

|===

== Description

pass:v,q[This container owns a url, represented] pass:v,q[by an inline, null-terminated character]
pass:v,q[buffer with fixed capacity.]
pass:v,q[The contents may be inspected and modified,]
pass:v,q[and the implementation maintains a useful]
pass:v,q[invariant: changes to the url always]
pass:v,q[leave it in a valid state.]

=== Example
[,cpp]
----
static_url< 1024 > u( "https://www.example.com" );
----

=== Invariants
[,cpp]
----
this->capacity() == Capacity
----




[#boost-urls-static_url-2destructor]

= Function static_url::~static_url

pass:v,q[Destructor]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L130[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
virtual
~static_url() = default;
----

== Description

pass:v,q[Any params, segments, iterators, or] pass:v,q[views which reference this object are]
pass:v,q[invalidated. The underlying character]
pass:v,q[buffer is destroyed, invalidating all]
pass:v,q[references to it.]



== Return Value

* `void` 





[#boost-urls-static_url-2constructor]

= Overload set static_url::static_url

== Members


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url() noexcept;
  xref:boost-urls-static_url-2constructor-098[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url(string_view s);
  xref:boost-urls-static_url-2constructor-08[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url(const xref:boost-urls-static_url[static_url]& u) noexcept;
  xref:boost-urls-static_url-2constructor-09f[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Constructor]


[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url(const xref:boost-urls-url_view_base[url_view_base]& u);
  xref:boost-urls-static_url-2constructor-0b[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-static_url-operator_assign]

= Overload set static_url::operator=

== Members


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
operator=(const xref:boost-urls-static_url[static_url]& u) noexcept;
  xref:boost-urls-static_url-operator_assign-06[pass:c,q,m[*_» more..._*]]
----


pass:v,q[Assignment]


[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
operator=(const xref:boost-urls-url_view_base[url_view_base]& u);
  xref:boost-urls-static_url-operator_assign-0c[pass:c,q,m[*_» more..._*]]
----


[#boost-urls-static_url-set_scheme]

= Function static_url::set_scheme

pass:v,q[Set the scheme]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L345[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_scheme(string_view s);
----

== Description

pass:v,q[The scheme is set to the specified] pass:v,q[string, which must contain a valid]
pass:v,q[scheme without any trailing colon]
pass:v,q[(':').]
pass:v,q[Note that schemes are case-insensitive,]
pass:v,q[and the canonical form is lowercased.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_scheme( "https" ).scheme_id() == scheme::https );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
scheme        = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[            3.1. Scheme (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_scheme_id]

= Function static_url::set_scheme_id

xref:boost-urls-url_base-set_scheme_id[url_base::set_scheme_id]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L347[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_scheme_id(xref:boost-urls-scheme[scheme] id);
----


[#boost-urls-static_url-remove_scheme]

= Function static_url::remove_scheme

pass:v,q[Remove the scheme]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L349[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_scheme();
----

== Description

pass:v,q[This function removes the scheme if it] pass:v,q[is present.]

=== Example
[,cpp]
----
assert( url("http://www.example.com/index.htm" ).remove_scheme().buffer() == "//www.example.com/index.htm" );
----

=== Postconditions
[,cpp]
----
this->has_scheme() == false && this->scheme_id() == scheme::none
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

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

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.1[            3.1. Scheme (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-set_encoded_authority]

= Function static_url::set_encoded_authority

pass:v,q[Set the authority]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L352[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_authority(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the authority] pass:v,q[to the specified string.] pass:v,q[The string may contain percent-escapes.]

=== Example
[,cpp]
----
assert( url().set_encoded_authority( "My%20Computer" ).has_authority() );
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = *( unreserved / pct-encoded / sub-delims / ":" )
host          = IP-literal / IPv4address / reg-name
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[            3.2. Authority (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-remove_authority]

= Function static_url::remove_authority

pass:v,q[Remove the authority]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L354[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_authority();
----

== Description

pass:v,q[This function removes the authority,] pass:v,q[which includes the userinfo, host, and]
pass:v,q[a port if present.]

=== Example
[,cpp]
----
assert( url( "http://example.com/echo.cgi" ).remove_authority().buffer() == "http:/echo.cgi" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == false && this->has_userinfo() == false && this->has_port() == false
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = *( unreserved / pct-encoded / sub-delims / ":" )
host          = IP-literal / IPv4address / reg-name
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[            3.2. Authority (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-set_userinfo]

= Function static_url::set_userinfo

pass:v,q[Set the userinfo]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L357[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_userinfo(string_view s);
----

== Description

pass:v,q[The userinfo is set to the given string,] pass:v,q[which may contain percent-escapes.]
pass:v,q[Any special or reserved characters in the]
pass:v,q[string are automatically percent-encoded.]
pass:v,q[The effects on the user and password]
pass:v,q[depend on the presence of a colon (':')]
pass:v,q[in the string:]

* pass:v,q[If an unescaped colon exists, the]
pass:v,q[characters up to the colon become]
pass:v,q[the user and the rest of the characters]
pass:v,q[after the colon become the password.]
pass:v,q[In this case]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns]
pass:v,q[true. Otherwise,]

* pass:v,q[If there is no colon, the user is]
pass:v,q[set to the string. The function]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns false.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_userinfo( "user:pass" ).encoded_user() == "user" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_userinfo]

= Function static_url::set_encoded_userinfo

pass:v,q[Set the userinfo.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L359[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_userinfo(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[The userinfo is set to the given string,] pass:v,q[which may contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The effects on the user and password]
pass:v,q[depend on the presence of a colon (':')]
pass:v,q[in the string:]

* pass:v,q[If an unescaped colon exists, the]
pass:v,q[characters up to the colon become]
pass:v,q[the user and the rest of the characters]
pass:v,q[after the colon become the password.]
pass:v,q[In this case]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns]
pass:v,q[true. Otherwise,]

* pass:v,q[If there is no colon, the user is]
pass:v,q[set to the string. The function]
xref:boost-urls-url_view_base-has_password[has_password]
pass:v,q[returns false.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_userinfo( "john%20doe" ).user() == "john doe" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-remove_userinfo]

= Function static_url::remove_userinfo

pass:v,q[Remove the userinfo]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L361[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_userinfo() noexcept;
----

== Description

pass:v,q[This function removes the userinfo if] pass:v,q[present, without removing any authority.]

=== Example
[,cpp]
----
assert( url( "http://user@example.com" ).remove_userinfo().has_userinfo() == false );
----

=== Postconditions
[,cpp]
----
this->has_userinfo() == false && this->encoded_userinfo().empty == true
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-set_user]

= Function static_url::set_user

pass:v,q[Set the user]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L363[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_user(string_view s);
----

== Description

pass:v,q[This function sets the user part of the] pass:v,q[userinfo to the string.]
pass:v,q[Any special or reserved characters in the]
pass:v,q[string are automatically percent-encoded.]

=== Example
[,cpp]
----
assert( url().set_user("john doe").encoded_userinfo() == "john%20doe" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_userinfo() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_user]

= Function static_url::set_encoded_user

pass:v,q[Set the user]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L365[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_user(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the user part of the] pass:v,q[userinfo the the string, which may]
pass:v,q[contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url().set_encoded_user("john%20doe").userinfo() == "john doe" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_userinfo() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-set_password]

= Function static_url::set_password

pass:v,q[Set the password.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L367[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_password(string_view s);
----

== Description

pass:v,q[This function sets the password in] pass:v,q[the userinfo to the string.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url("http://user@example.com").set_password( "pass" ).encoded_userinfo() == "user:pass" );
----

=== Postconditions
[,cpp]
----
this->has_password() == true && this->password() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_password]

= Function static_url::set_encoded_password

pass:v,q[Set the password.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L369[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_password(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the password in] pass:v,q[the userinfo to the string, which]
pass:v,q[may contain percent-escapes.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url("http://user@example.com").set_encoded_password( "pass" ).encoded_userinfo() == "user:pass" );
----

=== Postconditions
[,cpp]
----
this->has_password() == true
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-remove_password]

= Function static_url::remove_password

pass:v,q[Remove the password]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L371[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_password() noexcept;
----

== Description

pass:v,q[This function removes the password from] pass:v,q[the userinfo if a password exists. If]
pass:v,q[there is no userinfo or no authority,]
pass:v,q[the call has no effect.]
[NOTE]
pass:v,q[The interpretation of the userinfo as]
pass:v,q[individual user and password components]
pass:v,q[is scheme-dependent. Transmitting]
pass:v,q[passwords in URLs is deprecated.]

=== Example
[,cpp]
----
assert( url( "http://user:pass@example.com" ).remove_password().authority().buffer() == "user@example.com" );
----

=== Postconditions
[,cpp]
----
this->has_password() == false && this->encoded_password().empty() == true
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
userinfo      = [ [ user ] [ ':' password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.1[            3.2.1. User Information (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-set_host]

= Function static_url::set_host

pass:v,q[Set the host]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L374[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_host(string_view s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address]
pass:v,q[enclosed in square brackets, then the]
pass:v,q[host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture]
pass:v,q[address enclosed in square brackets, then]
pass:v,q[the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_host]

= Function static_url::set_encoded_host

pass:v,q[Set the host]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L376[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_host(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address]
pass:v,q[enclosed in square brackets, then the]
pass:v,q[host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture]
pass:v,q[address enclosed in square brackets, then]
pass:v,q[the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string. This string can contain percent]
pass:v,q[escapes, or can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
host        = IP-literal / IPv4address / reg-name

IP-literal  = "[" ( IPv6address / IPvFuture  ) "]"

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-set_host_address]

= Function static_url::set_host_address

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L378[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_host_address(string_view s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host_address( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255

IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal

IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_host_address]

= Function static_url::set_encoded_host_address

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L380[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_host_address(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[Depending on the contents of the passed] pass:v,q[string, this function sets the host:]

* pass:v,q[If the string is a valid IPv4 address,]
pass:v,q[then the host is set to the address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

* pass:v,q[If the string is a valid IPv6 address,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

* pass:v,q[If the string is a valid IPvFuture,]
pass:v,q[then the host is set to that address.]
pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

* pass:v,q[Otherwise, the host name is set to]
pass:v,q[the string. This string can contain percent]
pass:v,q[escapes, or can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]
pass:v,q[In all cases, when this function returns,]
pass:v,q[the URL contains an authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_host( "127.0.0.1" ).buffer() == "http://127.0.0.1" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255

IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal

IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )

reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-set_host_ipv4]

= Function static_url::set_host_ipv4

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L382[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_host_ipv4(const xref:boost-urls-ipv4_address[ipv4_address]& addr);
----

== Description

pass:v,q[The host is set to the specified IPv4] pass:v,q[address.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipv4[host_type::ipv4.]

=== Example
[,cpp]
----
assert( url("http://www.example.com").set_host_ipv4( ipv4_address( "127.0.0.1" ) ).buffer() == "http://127.0.0.1" );
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv4_address() == addr && this->host_type() == host_type::ipv4
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet

dec-octet   = DIGIT                 ; 0-9
            / %x31-39 DIGIT         ; 10-99
            / "1" 2DIGIT            ; 100-199
            / "2" %x30-34 DIGIT     ; 200-249
            / "25" %x30-35          ; 250-255
----

=== Specification

* link:https://en.wikipedia.org/wiki/IPv4[IPv4 (Wikipedia)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *addr*
| ``

|===




[#boost-urls-static_url-set_host_ipv6]

= Function static_url::set_host_ipv6

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L384[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_host_ipv6(const xref:boost-urls-ipv6_address[ipv6_address]& addr);
----

== Description

pass:v,q[The host is set to the specified IPv6] pass:v,q[address.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipv6[host_type::ipv6.]

=== Example
[,cpp]
----
assert( url().set_host_ipv6( ipv6_address( "1::6:c0a8:1" ) ).authority().buffer() == "[1::6:c0a8:1]" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::ipv6
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
IPv6address =                            6( h16 ":" ) ls32
            /                       "::" 5( h16 ":" ) ls32
            / [               h16 ] "::" 4( h16 ":" ) ls32
            / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
            / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
            / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
            / [ *4( h16 ":" ) h16 ] "::"              ls32
            / [ *5( h16 ":" ) h16 ] "::"              h16
            / [ *6( h16 ":" ) h16 ] "::"

ls32        = ( h16 ":" h16 ) / IPv4address
            ; least-significant 32 bits of address

h16         = 1*4HEXDIG
            ; 16 bits of address represented in hexadecimal
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291[IP Version 6 Addressing Architecture (rfc4291)]

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *addr*
| ``

|===




[#boost-urls-static_url-set_host_ipvfuture]

= Function static_url::set_host_ipvfuture

pass:v,q[Set the host to an address]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L386[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_host_ipvfuture(string_view s);
----

== Description

pass:v,q[The host is set to the specified IPvFuture] pass:v,q[string.] pass:v,q[The host type is]
xref:boost-urls-host_type-ipvfuture[host_type::ipvfuture.]

=== Example
[,cpp]
----
assert( url().set_host_ipvfuture( "v42.bis" ).buffer() == "//[v42.bis]" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipvfuture) == s && this->host_type() == host_type::ipvfuture
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_host_name]

= Function static_url::set_host_name

pass:v,q[Set the host to a name]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L388[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_host_name(string_view s);
----

== Description

pass:v,q[The host is set to the specified string,] pass:v,q[which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm").set_host_name( "localhost" ).host_address() == "localhost" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::name
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_host_name]

= Function static_url::set_encoded_host_name

pass:v,q[Set the host to a name]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L390[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_host_name(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[The host is set to the specified string,] pass:v,q[which may contain percent-escapes and]
pass:v,q[can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
pass:v,q[The host type is]
xref:boost-urls-host_type-name[host_type::name.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm").set_encoded_host_name( "localhost" ).host_address() == "localhost" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->host_ipv6_address() == addr && this->host_type() == host_type::name
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
reg-name    = *( unreserved / pct-encoded / "-" / ".")
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[            3.2.2. Host (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-set_port_number]

= Function static_url::set_port_number

pass:v,q[Set the port]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L392[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_port_number(uint16_t n);
----

== Description

pass:v,q[The port is set to the specified integer.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_port_number( 8080 ).authority().buffer() == "www.example.com:8080" );
----

=== Postconditions
[,cpp]
----
this->has_authority() == true && this->has_port() == true && this->port_number() == n
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *n*
| `uint16_t`

|===




[#boost-urls-static_url-set_port]

= Function static_url::set_port

pass:v,q[Set the port]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L394[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_port(string_view s);
----

== Description

pass:v,q[This port is set to the string, which] pass:v,q[must contain only digits or be empty.]
pass:v,q[An empty port string is distinct from]
pass:v,q[having no port.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com" ).set_port( "8080" ).authority().buffer() == "www.example.com:8080" );
----

=== Postconditions
[,cpp]
----
this->has_port() == true && this->port_number() == n && this->port() == std::to_string(n)
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-remove_port]

= Function static_url::remove_port

pass:v,q[Remove the port]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L396[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_port() noexcept;
----

== Description

pass:v,q[If a port exists, it is removed. The rest] pass:v,q[of the authority is unchanged.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com:80" ).remove_port().authority().buffer() == "www.example.com" );
----

=== Postconditions
[,cpp]
----
this->has_port() == false && this->port_number() == 0 && this->port() == ""
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.3[            3.2.3. Port (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-set_path]

= Function static_url::set_path

pass:v,q[Set the path.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L401[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_path(string_view s);
----

== Description

pass:v,q[This function sets the path to the] pass:v,q[string, which may be empty.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]
[NOTE]
pass:v,q[The library may adjust the final result]
pass:v,q[to ensure that no other parts of the url]
pass:v,q[is semantically affected.]
[NOTE]
pass:v,q[This function does not encode '/' chars, which]
pass:v,q[are unreserved for paths but reserved for]
pass:v,q[path segments. If a path segment should include]
pass:v,q[encoded '/'s to differentiate it from path separators,]
pass:v,q[the functions]
xref:boost-urls-url_base-set_encoded_path[set_encoded_path]
pass:v,q[or]
xref:boost-urls-url_base-segments-04[segments]
pass:v,q[should be used instead.]

=== Example
[,cpp]
----
url u( "http://www.example.com" );

u.set_path( "path/to/file.txt" );

assert( u.path() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_path]

= Function static_url::set_encoded_path

pass:v,q[Set the path.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L403[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_path(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the path to the] pass:v,q[string, which may contain percent-escapes]
pass:v,q[and can be empty.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]
[NOTE]
pass:v,q[The library may adjust the final result]
pass:v,q[to ensure that no other parts of the url]
pass:v,q[is semantically affected.]

=== Example
[,cpp]
----
url u( "http://www.example.com" );

u.set_encoded_path( "path/to/file.txt" );

assert( u.encoded_path() == "/path/to/file.txt" );
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-set_query]

= Function static_url::set_query

pass:v,q[Set the query]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L406[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_query(string_view s);
----

== Description

pass:v,q[This sets the query to the string, which] pass:v,q[can be empty.] pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_query( "id=42" ).query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true && this->query() == s
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_query]

= Function static_url::set_encoded_query

pass:v,q[Set the query]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L408[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_query(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This sets the query to the string, which] pass:v,q[may contain percent-escapes and can be]
pass:v,q[empty.]
pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url( "http://example.com" ).set_encoded_query( "id=42" ).encoded_query() == "id=42" );
----

=== Postconditions
[,cpp]
----
this->has_query() == true && this->query() == decode_view( s );
----

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-remove_query]

= Function static_url::remove_query

pass:v,q[Remove the query]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L410[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_query() noexcept;
----

== Description

pass:v,q[If a query is present, it is removed.] pass:v,q[An empty query is distinct from having]
pass:v,q[no query.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com?id=42" ).remove_query().buffer() == "http://www.example.com" );
----

=== Postconditions
[,cpp]
----
this->has_query() == false && this->params().empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `` 





[#boost-urls-static_url-remove_fragment]

= Function static_url::remove_fragment

pass:v,q[Remove the fragment]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L413[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_fragment() noexcept;
----

== Description

pass:v,q[This function removes the fragment.] pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]

=== Example
[,cpp]
----
assert( url( "?first=john&last=doe#anchor" ).remove_fragment().buffer() == "?first=john&last=doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == false && this->encoded_fragment() == ""
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 





[#boost-urls-static_url-set_fragment]

= Function static_url::set_fragment

pass:v,q[Set the fragment.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L415[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_fragment(string_view s);
----

== Description

pass:v,q[This function sets the fragment to the] pass:v,q[specified string, which may be empty.]
pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]
pass:v,q[Reserved characters in the string are]
pass:v,q[percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url("?first=john&last=doe" ).set_encoded_fragment( "john doe" ).encoded_fragment() == "john%20doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == true && this->fragment() == s
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-set_encoded_fragment]

= Function static_url::set_encoded_fragment

pass:v,q[Set the fragment.]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L417[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
set_encoded_fragment(xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function sets the fragment to the] pass:v,q[specified string, which may contain]
pass:v,q[percent-escapes and which may be empty.]
pass:v,q[An empty fragment is distinct from]
pass:v,q[having no fragment.]
pass:v,q[Escapes in the string are preserved,]
pass:v,q[and reserved characters in the string]
pass:v,q[are percent-escaped in the result.]

=== Example
[,cpp]
----
assert( url("?first=john&last=doe" ).set_encoded_fragment( "john%2Ddoe" ).fragment() == "john-doe" );
----

=== Postconditions
[,cpp]
----
this->has_fragment() == true && this->fragment() == decode_view( s )
----

=== Complexity
pass:v,q[Linear in `this->size() + s.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
fragment    = *( pchar / "/" / "?" )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.5[3.5.  Fragment]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

|===




[#boost-urls-static_url-remove_origin]

= Function static_url::remove_origin

pass:v,q[Remove the origin component]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L420[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
remove_origin();
----

== Description

pass:v,q[This function removes the origin, which] pass:v,q[consists of the scheme and authority.]

=== Example
[,cpp]
----
assert( url( "http://www.example.com/index.htm" ).remove_origin().buffer() == "/index.htm" );
----

=== Postconditions
[,cpp]
----
this->scheme_id() == scheme::none && this->has_authority() == false
----

=== Complexity
pass:v,q[Linear in `this->size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 





[#boost-urls-static_url-normalize]

= Function static_url::normalize

pass:v,q[Normalize the URL components]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L423[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
normalize();
----

== Description

pass:v,q[Applies Syntax-based normalization to] pass:v,q[all components of the URL.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-normalize_scheme]

= Function static_url::normalize_scheme

pass:v,q[Normalize the URL scheme]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L425[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
normalize_scheme();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL scheme.]
pass:v,q[The scheme is normalized to lowercase.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-normalize_authority]

= Function static_url::normalize_authority

pass:v,q[Normalize the URL authority]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L427[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
normalize_authority();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL authority.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-normalize_path]

= Function static_url::normalize_path

pass:v,q[Normalize the URL path]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L429[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
normalize_path();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL path.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded. Redundant]
pass:v,q[path-segments are removed.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-normalize_query]

= Function static_url::normalize_query

pass:v,q[Normalize the URL query]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L431[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
normalize_query();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL query.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url-normalize_fragment]

= Function static_url::normalize_fragment

pass:v,q[Normalize the URL fragment]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L433[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
normalize_fragment();
----

== Description

pass:v,q[Applies Syntax-based normalization to the] pass:v,q[URL fragment.]
pass:v,q[Percent-encoding triplets are normalized]
pass:v,q[to uppercase letters. Percent-encoded]
pass:v,q[octets that correspond to unreserved]
pass:v,q[characters are decoded.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `` 





[#boost-urls-static_url_base]

= Class static_url_base

pass:v,q[Common implementation for all static URLs]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L52[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
class static_url_base
    : public xref:boost-urls-url_base[url_base];
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-authority[`pass:v[authority]`] |
pass:v,q[Return the authority]

|xref:boost-urls-url_view_base-buffer[`pass:v[buffer]`] |
pass:v,q[Return the url string]

|xref:boost-urls-url_base-c_str[`pass:v[c_str]`] |
pass:v,q[Return the url as a null-terminated string]

|xref:boost-urls-url_base-capacity[`pass:v[capacity]`] |
pass:v,q[Return the number of characters that can be stored without reallocating]

|xref:boost-urls-url_base-clear[`pass:v[clear]`] |
pass:v,q[Clear the contents while preserving the capacity]

|xref:boost-urls-url_view_base-compare[`pass:v[compare]`] |
pass:v,q[Return the result of comparing this with another url]

|xref:boost-urls-url_view_base-data[`pass:v[data]`] |
pass:v,q[Return a pointer to the url's character buffer]

|xref:boost-urls-url_view_base-digest[`pass:v[digest]`] |

|xref:boost-urls-url_view_base-empty[`pass:v[empty]`] |
pass:v,q[Return true if the url is empty]

|xref:boost-urls-url_view_base-encoded_authority[`pass:v[encoded_authority]`] |
pass:v,q[Return the authority.]

|xref:boost-urls-url_view_base-encoded_fragment[`pass:v[encoded_fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-encoded_host[`pass:v[encoded_host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_address[`pass:v[encoded_host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-encoded_host_and_port[`pass:v[encoded_host_and_port]`] |
pass:v,q[Return the host and port]

|xref:boost-urls-url_view_base-encoded_host_name[`pass:v[encoded_host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-encoded_origin[`pass:v[encoded_origin]`] |
pass:v,q[Return the origin]

|xref:boost-urls-url_view_base-encoded_params[`pass:v[encoded_params]`] |
pass:v,q[Return the query as a container of parameters]

|xref:boost-urls-url_view_base-encoded_password[`pass:v[encoded_password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-encoded_path[`pass:v[encoded_path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-encoded_query[`pass:v[encoded_query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_view_base-encoded_resource[`pass:v[encoded_resource]`] |
pass:v,q[Return the resource]

|xref:boost-urls-url_view_base-encoded_segments[`pass:v[encoded_segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_view_base-encoded_target[`pass:v[encoded_target]`] |
pass:v,q[Return the target]

|xref:boost-urls-url_view_base-encoded_user[`pass:v[encoded_user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-encoded_userinfo[`pass:v[encoded_userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-encoded_zone_id[`pass:v[encoded_zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|xref:boost-urls-url_view_base-fragment[`pass:v[fragment]`] |
pass:v,q[Return the fragment]

|xref:boost-urls-url_view_base-has_authority[`pass:v[has_authority]`] |
pass:v,q[Return true if an authority is present]

|xref:boost-urls-url_view_base-has_fragment[`pass:v[has_fragment]`] |
pass:v,q[Return true if a fragment is present]

|xref:boost-urls-url_view_base-has_password[`pass:v[has_password]`] |
pass:v,q[Return true if a password is present]

|xref:boost-urls-url_view_base-has_port[`pass:v[has_port]`] |
pass:v,q[Return true if a port is present]

|xref:boost-urls-url_view_base-has_query[`pass:v[has_query]`] |
pass:v,q[Return true if a query is present]

|xref:boost-urls-url_view_base-has_scheme[`pass:v[has_scheme]`] |
pass:v,q[Return true a scheme is present]

|xref:boost-urls-url_view_base-has_userinfo[`pass:v[has_userinfo]`] |
pass:v,q[Return true if a userinfo is present]

|xref:boost-urls-url_view_base-host[`pass:v[host]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_address[`pass:v[host_address]`] |
pass:v,q[Return the host]

|xref:boost-urls-url_view_base-host_ipv4_address[`pass:v[host_ipv4_address]`] |
pass:v,q[Return the host IPv4 address]

|xref:boost-urls-url_view_base-host_ipv6_address[`pass:v[host_ipv6_address]`] |
pass:v,q[Return the host IPv6 address]

|xref:boost-urls-url_view_base-host_ipvfuture[`pass:v[host_ipvfuture]`] |
pass:v,q[Return the host IPvFuture address]

|xref:boost-urls-url_view_base-host_name[`pass:v[host_name]`] |
pass:v,q[Return the host name]

|xref:boost-urls-url_view_base-host_type[`pass:v[host_type]`] |
pass:v,q[Return the host type]

|xref:boost-urls-url_view_base-is_path_absolute[`pass:v[is_path_absolute]`] |
pass:v,q[Return true if the path is absolute]

|xref:boost-urls-url_base-normalize[`pass:v[normalize]`] |
pass:v,q[Normalize the URL components]

|xref:boost-urls-url_base-normalize_authority[`pass:v[normalize_authority]`] |
pass:v,q[Normalize the URL authority]

|xref:boost-urls-url_base-normalize_fragment[`pass:v[normalize_fragment]`] |
pass:v,q[Normalize the URL fragment]

|xref:boost-urls-url_base-normalize_path[`pass:v[normalize_path]`] |
pass:v,q[Normalize the URL path]

|xref:boost-urls-url_base-normalize_query[`pass:v[normalize_query]`] |
pass:v,q[Normalize the URL query]

|xref:boost-urls-url_base-normalize_scheme[`pass:v[normalize_scheme]`] |
pass:v,q[Normalize the URL scheme]

|xref:boost-urls-url_view_base-2conversion[`pass:v[operator string_view]`] |
pass:v,q[Return the URL as a core::string_view]

|xref:boost-urls-url_view_base-params[`pass:v[params]`] |
pass:v,q[Return the query as a container of parameters]

xref:boost-urls-url_view_base-params-05[url_view_base::params]

|xref:boost-urls-url_view_base-password[`pass:v[password]`] |
pass:v,q[Return the password]

|xref:boost-urls-url_view_base-path[`pass:v[path]`] |
pass:v,q[Return the path]

|xref:boost-urls-url_view_base-persist[`pass:v[persist]`] |
pass:v,q[Return a shared, persistent copy of the url]

|xref:boost-urls-url_view_base-port[`pass:v[port]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-port_number[`pass:v[port_number]`] |
pass:v,q[Return the port]

|xref:boost-urls-url_view_base-query[`pass:v[query]`] |
pass:v,q[Return the query]

|xref:boost-urls-url_base-remove_authority[`pass:v[remove_authority]`] |
pass:v,q[Remove the authority]

|xref:boost-urls-url_base-remove_fragment[`pass:v[remove_fragment]`] |
pass:v,q[Remove the fragment]

|xref:boost-urls-url_base-remove_origin[`pass:v[remove_origin]`] |
pass:v,q[Remove the origin component]

|xref:boost-urls-url_base-remove_password[`pass:v[remove_password]`] |
pass:v,q[Remove the password]

|xref:boost-urls-url_base-remove_port[`pass:v[remove_port]`] |
pass:v,q[Remove the port]

|xref:boost-urls-url_base-remove_query[`pass:v[remove_query]`] |
pass:v,q[Remove the query]

|xref:boost-urls-url_base-remove_scheme[`pass:v[remove_scheme]`] |
pass:v,q[Remove the scheme]

|xref:boost-urls-url_base-remove_userinfo[`pass:v[remove_userinfo]`] |
pass:v,q[Remove the userinfo]

|xref:boost-urls-url_base-reserve[`pass:v[reserve]`] |
pass:v,q[Adjust the capacity without changing the size]

|xref:boost-urls-url_base-resolve[`pass:v[resolve]`] |
pass:v,q[Resolve a URL reference against this base URL]

|xref:boost-urls-url_view_base-scheme[`pass:v[scheme]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-scheme_id[`pass:v[scheme_id]`] |
pass:v,q[Return the scheme]

|xref:boost-urls-url_view_base-segments[`pass:v[segments]`] |
pass:v,q[Return the path as a container of segments]

|xref:boost-urls-url_base-set_encoded_authority[`pass:v[set_encoded_authority]`] |
pass:v,q[Set the authority]

|xref:boost-urls-url_base-set_encoded_fragment[`pass:v[set_encoded_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_encoded_host[`pass:v[set_encoded_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_encoded_host_address[`pass:v[set_encoded_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_encoded_host_name[`pass:v[set_encoded_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_encoded_params[`pass:v[set_encoded_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_encoded_password[`pass:v[set_encoded_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_encoded_path[`pass:v[set_encoded_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_encoded_query[`pass:v[set_encoded_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_encoded_user[`pass:v[set_encoded_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_encoded_userinfo[`pass:v[set_encoded_userinfo]`] |
pass:v,q[Set the userinfo.]

|xref:boost-urls-url_base-set_fragment[`pass:v[set_fragment]`] |
pass:v,q[Set the fragment.]

|xref:boost-urls-url_base-set_host[`pass:v[set_host]`] |
pass:v,q[Set the host]

|xref:boost-urls-url_base-set_host_address[`pass:v[set_host_address]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv4[`pass:v[set_host_ipv4]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipv6[`pass:v[set_host_ipv6]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_ipvfuture[`pass:v[set_host_ipvfuture]`] |
pass:v,q[Set the host to an address]

|xref:boost-urls-url_base-set_host_name[`pass:v[set_host_name]`] |
pass:v,q[Set the host to a name]

|xref:boost-urls-url_base-set_params[`pass:v[set_params]`] |
pass:v,q[Set the query params]

|xref:boost-urls-url_base-set_password[`pass:v[set_password]`] |
pass:v,q[Set the password.]

|xref:boost-urls-url_base-set_path[`pass:v[set_path]`] |
pass:v,q[Set the path.]

|xref:boost-urls-url_base-set_path_absolute[`pass:v[set_path_absolute]`] |
pass:v,q[Set if the path is absolute]

|xref:boost-urls-url_base-set_port[`pass:v[set_port]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_port_number[`pass:v[set_port_number]`] |
pass:v,q[Set the port]

|xref:boost-urls-url_base-set_query[`pass:v[set_query]`] |
pass:v,q[Set the query]

|xref:boost-urls-url_base-set_scheme[`pass:v[set_scheme]`] |
pass:v,q[Set the scheme]

|xref:boost-urls-url_base-set_scheme_id[`pass:v[set_scheme_id]`] |

|xref:boost-urls-url_base-set_user[`pass:v[set_user]`] |
pass:v,q[Set the user]

|xref:boost-urls-url_base-set_userinfo[`pass:v[set_userinfo]`] |
pass:v,q[Set the userinfo]

|xref:boost-urls-url_view_base-size[`pass:v[size]`] |
pass:v,q[Return the number of characters in the url]

|xref:boost-urls-url_view_base-user[`pass:v[user]`] |
pass:v,q[Return the user]

|xref:boost-urls-url_view_base-userinfo[`pass:v[userinfo]`] |
pass:v,q[Return the userinfo]

|xref:boost-urls-url_view_base-zone_id[`pass:v[zone_id]`] |
pass:v,q[Return the IPv6 Zone ID]

|===
==  Static Member Functions
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-max_size[`pass:v[max_size]`] |
pass:v,q[Return the maximum number of characters possible]

|===
==  Friends
[,cols=2]
|===
|Name |Description
|xref:boost-urls-url_view_base-8friend-02[`pass:v[operator!=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-05[`pass:v[operator<]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-03[`pass:v[operator<<]`] |

|xref:boost-urls-url_view_base-8friend-04[`pass:v[operator<=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-07c[`pass:v[operator==]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-073[`pass:v[operator>]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_view_base-8friend-06[`pass:v[operator>=]`] |
pass:v,q[Return the result of comparing two URLs]

|xref:boost-urls-url_base-8friend[`pass:v[resolve]`] |

|===

== Description

pass:v,q[This base class is used by the library] pass:v,q[to provide common functionality for]
pass:v,q[static URLs. Users should not use this]
pass:v,q[class directly. Instead, construct an]
pass:v,q[instance of one of the containers]
pass:v,q[or call a parsing function.]

=== Containers

* xref:boost-urls-url[url]

* xref:boost-urls-url_view[url_view]

* xref:boost-urls-static_url[static_url]

=== Parsing Functions

* xref:boost-urls-parse_absolute_uri[parse_absolute_uri]

* xref:boost-urls-parse_origin_form[parse_origin_form]

* xref:boost-urls-parse_relative_ref[parse_relative_ref]

* xref:boost-urls-parse_uri[parse_uri]

* xref:boost-urls-parse_uri_reference[parse_uri_reference]




[#boost-system]

= Namespace system

==  Types
[,cols=2]
|===
|Name |Description
|xref:boost-system-is_error_code_enum-01[`pass:v[is_error_code_enum<urls::error>]`] |

|xref:boost-system-is_error_code_enum-0e[`pass:v[is_error_code_enum<urls::grammar::error>]`] |

|xref:boost-system-is_error_condition_enum[`pass:v[is_error_condition_enum<urls::grammar::condition>]`] |

|===

[#boost-system-is_error_code_enum-01]

= Class is_error_code_enum



== Synopsis

Declared in header `</boost/url/impl/error.hpp#L20[boost/url/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<>
struct is_error_code_enum<xref:boost-urls[urls]::xref:boost-urls-error[error]>;
----

==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-system-is_error_code_enum-01-value[`pass:v[value]`] |

|===



[#boost-system-is_error_code_enum-01-value]

= is_error_code_enum::value



== Synopsis

Declared in header `</boost/url/impl/error.hpp#L22[boost/url/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static
const bool value;
----


[#boost-system-is_error_code_enum-0e]

= Class is_error_code_enum



== Synopsis

Declared in header `</boost/url/grammar/impl/error.hpp#L18[boost/url/grammar/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<>
struct is_error_code_enum<xref:boost-urls[urls]::xref:boost-urls-grammar[grammar]::xref:boost-urls-grammar-error[error]>;
----

==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-system-is_error_code_enum-0e-value[`pass:v[value]`] |

|===



[#boost-system-is_error_code_enum-0e-value]

= is_error_code_enum::value



== Synopsis

Declared in header `</boost/url/grammar/impl/error.hpp#L21[boost/url/grammar/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static
const bool value;
----


[#boost-system-is_error_condition_enum]

= Class is_error_condition_enum



== Synopsis

Declared in header `</boost/url/grammar/impl/error.hpp#L24[boost/url/grammar/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<>
struct is_error_condition_enum<xref:boost-urls[urls]::xref:boost-urls-grammar[grammar]::xref:boost-urls-grammar-condition[condition]>;
----

==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:boost-system-is_error_condition_enum-value[`pass:v[value]`] |

|===



[#boost-system-is_error_condition_enum-value]

= is_error_condition_enum::value



== Synopsis

Declared in header `</boost/url/grammar/impl/error.hpp#L27[boost/url/grammar/impl/error.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static
const bool value;
----


[#std]

= Namespace std

==  Types
[,cols=2]
|===
|Name |Description
|xref:std-__is_nothrow_constructible_impl[`pass:v[__is_nothrow_constructible_impl]`] |

|xref:std-false_type[`pass:v[false_type]`] |

|xref:std-hash-04[`pass:v[hash<boost::urls::url>]`] |

|xref:std-hash-0c[`pass:v[hash<boost::urls::url_view>]`] |

|xref:std-hash-06[`pass:v[hash<boost::urls::static_url<N>>]`] |

|xref:std-integral_constant[`pass:v[integral_constant]`] |

|xref:std-is_nothrow_copy_constructible[`pass:v[is_nothrow_copy_constructible]`] |

|xref:std-true_type[`pass:v[true_type]`] |

|===

[#std-is_nothrow_copy_constructible]

= Class is_nothrow_copy_constructible



== Synopsis

Declared in header `</type_traits#L1131[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct is_nothrow_copy_constructible
    : xref:std-__is_nothrow_constructible_impl[__is_nothrow_constructible_impl]<_Tp, __add_lval_ref_t<const _Tp>>;
----




[#std-true_type]

= true_type



== Synopsis

Declared in header `</type_traits#L82[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using true_type = xref:std-integral_constant[integral_constant]<bool, true>;
----


[#std-integral_constant]

= Class integral_constant



== Synopsis

Declared in header `</type_traits#L62[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
struct integral_constant;
----

==  Types
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-type[`pass:v[type]`] |

|xref:std-integral_constant-value_type[`pass:v[value_type]`] |

|===
==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-2conversion[`pass:v[operator integral_constant::value_type]`] |

|xref:std-integral_constant-operator_call[`pass:v[operator()]`] |

|===
==  Static Data Members
[,cols=2]
|===
|Name |Description
|xref:std-integral_constant-value[`pass:v[value]`] |

|===



[#std-integral_constant-value]

= integral_constant::value



== Synopsis

Declared in header `</type_traits#L64[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
static
const _Tp value;
----


[#std-integral_constant-value_type]

= integral_constant::value_type



== Synopsis

Declared in header `</type_traits#L65[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef _Tp value_type;
----


[#std-integral_constant-type]

= integral_constant::type



== Synopsis

Declared in header `</type_traits#L66[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
typedef xref:std-integral_constant[integral_constant]<_Tp, __v> type;
----


[#std-integral_constant-2conversion]

= Function integral_constant::operator value_type



== Synopsis

Declared in header `</type_traits#L67[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
operator xref:std-integral_constant-value_type[value_type]() const noexcept;
----


[#std-integral_constant-operator_call]

= Function integral_constant::operator()



== Synopsis

Declared in header `</type_traits#L72[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:std-integral_constant-value_type[value_type]
operator()() const noexcept;
----


[#std-false_type]

= false_type



== Synopsis

Declared in header `</type_traits#L85[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
using false_type = xref:std-integral_constant[integral_constant]<bool, false>;
----


[#std-__is_nothrow_constructible_impl]

= __is_nothrow_constructible_impl



== Synopsis

Declared in header `</type_traits#L1107[type_traits,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    typename _Tp,
    typename... _Args>
using __is_nothrow_constructible_impl = __bool_constant<__is_nothrow_constructible(_Tp, _Args...)>;
----


[#std-hash-04]

= Class hash



== Synopsis

Declared in header `</boost/url/url.hpp#L523[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<>
struct hash<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url[url]>;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-hash-04-2constructor[`pass:v[hash]`] |
|xref:std-hash-04-operator_call[`pass:v[operator()]`] |

|xref:std-hash-04-operator_assign[`pass:v[operator=]`] |

|===



[#std-hash-04-2constructor]

= Overload set hash::hash

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash() = default;
  xref:std-hash-04-2constructor-01[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash(const xref:std-hash-04[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url[url]>&) = default;
  xref:std-hash-04-2constructor-00[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(size_t salt) noexcept;
  xref:std-hash-04-2constructor-06[pass:c,q,m[*_» more..._*]]
----


[#std-hash-04-operator_assign]

= Function hash::operator=



== Synopsis

Declared in header `</boost/url/url.hpp#L527[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:std-hash-04[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url[url]>&
operator=(const xref:std-hash-04[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url[url]>&) = default;
----


[#std-hash-04-operator_call]

= Function hash::operator()



== Synopsis

Declared in header `</boost/url/url.hpp#L535[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
operator()(const xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url[url]& u) const noexcept;
----


[#std-hash-0c]

= Class hash



== Synopsis

Declared in header `</boost/url/url_view.hpp#L349[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<>
struct hash<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url_view[url_view]>;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-hash-0c-2constructor[`pass:v[hash]`] |
|xref:std-hash-0c-operator_call[`pass:v[operator()]`] |

|xref:std-hash-0c-operator_assign[`pass:v[operator=]`] |

|===



[#std-hash-0c-2constructor]

= Overload set hash::hash

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash() = default;
  xref:std-hash-0c-2constructor-07[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash(const xref:std-hash-0c[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url_view[url_view]>&) = default;
  xref:std-hash-0c-2constructor-00[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(size_t salt) noexcept;
  xref:std-hash-0c-2constructor-05[pass:c,q,m[*_» more..._*]]
----


[#std-hash-0c-operator_assign]

= Function hash::operator=



== Synopsis

Declared in header `</boost/url/url_view.hpp#L353[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:std-hash-0c[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url_view[url_view]>&
operator=(const xref:std-hash-0c[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url_view[url_view]>&) = default;
----


[#std-hash-0c-operator_call]

= Function hash::operator()



== Synopsis

Declared in header `</boost/url/url_view.hpp#L361[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
operator()(const xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url_view[url_view]& u) const noexcept;
----


[#std-hash-06]

= Class hash



== Synopsis

Declared in header `</boost/url/static_url.hpp#L447[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<size_t N>
struct hash<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-static_url[static_url]<N>>;
----

==  Member Functions
[,cols=2]
|===
|Name |Description
|xref:std-hash-06-2constructor[`pass:v[hash]`] |
|xref:std-hash-06-operator_call[`pass:v[operator()]`] |

|xref:std-hash-06-operator_assign[`pass:v[operator=]`] |

|===



[#std-hash-06-2constructor]

= Overload set hash::hash

== Members




[source,cpp,subs="verbatim,macros,-callouts"]
----
hash() = default;
  xref:std-hash-06-2constructor-0c[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(const xref:std-hash-06[hash]&) = default;
  xref:std-hash-06-2constructor-06[pass:c,q,m[*_» more..._*]]
----




[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(size_t salt) noexcept;
  xref:std-hash-06-2constructor-0f[pass:c,q,m[*_» more..._*]]
----


[#std-hash-06-operator_assign]

= Function hash::operator=



== Synopsis

Declared in header `</boost/url/static_url.hpp#L451[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:std-hash-06[hash]&
operator=(const xref:std-hash-06[hash]&) = default;
----


[#std-hash-06-operator_call]

= Function hash::operator()



== Synopsis

Declared in header `</boost/url/static_url.hpp#L459[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
operator()(const xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-static_url[static_url]<N>& u) const noexcept;
----


[#boost-urls-grammar-lut_chars-2constructor-079]

= Function lut_chars::lut_chars

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L157[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
lut_chars(char ch) noexcept;
----

== Description

pass:v,q[This function constructs a character] pass:v,q[set which has as a single member,]
pass:v,q[the character `ch`.]

=== Example
[,cpp]
----
constexpr lut_chars asterisk( '*' );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *ch*
| `char`

|===




[#boost-urls-grammar-lut_chars-2constructor-074]

= Function lut_chars::lut_chars

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L188[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
lut_chars(const char* s) noexcept;
----

== Description

pass:v,q[This function constructs a character] pass:v,q[set which has as members, all of the]
pass:v,q[characters present in the null-terminated]
pass:v,q[string `s`.]

=== Example
[,cpp]
----
constexpr lut_chars digits = "0123456789";
----

=== Complexity
pass:v,q[Linear in `::strlen(s)`, or constant]
pass:v,q[if `s` is a constant expression.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| ``

|===




[#boost-urls-grammar-lut_chars-2constructor-02]

= Function lut_chars::lut_chars



== Synopsis

Declared in header `</boost/url/grammar/lut_chars.hpp#L235[boost/url/grammar/lut_chars.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class Pred,
    class = enable_if<detail::is_pred<Pred>::value && !std::is_base_of<lut_chars, Pred>::value>::type>
constexpr
lut_chars(const Pred& pred) noexcept;
----


[#boost-urls-grammar-string_view_base-starts_with-06]

= Function string_view_base::starts_with

pass:v,q[Return true if a matching prefix exists]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L419[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
starts_with(string_view x) const noexcept;
----

== Description

pass:v,q[See `core::string_view::starts_with`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *x*
| `string_view`

|===




[#boost-urls-grammar-string_view_base-starts_with-0b]

= Function string_view_base::starts_with

pass:v,q[Return true if a matching prefix exists]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L429[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
starts_with(char x) const noexcept;
----

== Description

pass:v,q[See `core::string_view::starts_with`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *x*
| `char`

|===




[#boost-urls-grammar-string_view_base-starts_with-0d]

= Function string_view_base::starts_with

pass:v,q[Return true if a matching prefix exists]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L439[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
starts_with(const char* x) const noexcept;
----

== Description

pass:v,q[See `core::string_view::starts_with`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *x*
| ``

|===




[#boost-urls-grammar-string_view_base-ends_with-0a]

= Function string_view_base::ends_with

pass:v,q[Return true if a matching suffix exists]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L451[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
ends_with(string_view x) const noexcept;
----

== Description

pass:v,q[See `core::string_view::ends_with`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *x*
| `string_view`

|===




[#boost-urls-grammar-string_view_base-ends_with-06]

= Function string_view_base::ends_with

pass:v,q[Return true if a matching suffix exists]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L461[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
ends_with(char x) const noexcept;
----

== Description

pass:v,q[See `core::string_view::ends_with`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *x*
| `char`

|===




[#boost-urls-grammar-string_view_base-ends_with-0c]

= Function string_view_base::ends_with

pass:v,q[Return true if a matching suffix exists]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L471[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
ends_with(const char* x) const noexcept;
----

== Description

pass:v,q[See `core::string_view::ends_with`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *x*
| ``

|===




[#boost-urls-grammar-string_view_base-find-0d]

= Function string_view_base::find

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L483[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *str*
| `string_view`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find-00]

= Function string_view_base::find

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L493[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find-07]

= Function string_view_base::find

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L503[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

| *n*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find-0c]

= Function string_view_base::find

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L513[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-rfind-0ed]

= Function string_view_base::rfind

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L525[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::rfind`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *str*
| `string_view`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-rfind-0eb]

= Function string_view_base::rfind

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L535[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::rfind`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-rfind-0b]

= Function string_view_base::rfind

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L545[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
----

== Description

pass:v,q[See `core::string_view::rfind`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

| *n*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-rfind-0d]

= Function string_view_base::rfind

pass:v,q[Return the position of matching characters]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L555[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
rfind(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::rfind`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-compare-02]

= Function string_view_base::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L355[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(string_view str) const noexcept;
----

== Description

pass:v,q[See `core::string_view::compare`]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *str*
| `string_view`

|===




[#boost-urls-grammar-string_view_base-compare-0a]

= Function string_view_base::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L365[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    string_view str) const;
----

== Description

pass:v,q[See `core::string_view::compare`]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *pos1*
| `size_type`

| *n1*
| `size_type`

| *str*
| `string_view`

|===




[#boost-urls-grammar-string_view_base-compare-0e]

= Function string_view_base::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L375[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos2,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n2) const;
----

== Description

pass:v,q[See `core::string_view::compare`]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *pos1*
| `size_type`

| *n1*
| `size_type`

| *str*
| `string_view`

| *pos2*
| `size_type`

| *n2*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-compare-07]

= Function string_view_base::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L386[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(const char* s) const noexcept;
----

== Description

pass:v,q[See `core::string_view::compare`]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *s*
| ``

|===




[#boost-urls-grammar-string_view_base-compare-0b]

= Function string_view_base::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L396[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    const char* s) const;
----

== Description

pass:v,q[See `core::string_view::compare`]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *pos1*
| `size_type`

| *n1*
| `size_type`

| *s*
| ``

|===




[#boost-urls-grammar-string_view_base-compare-0c]

= Function string_view_base::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L406[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
int
compare(
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos1,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n1,
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n2) const;
----

== Description

pass:v,q[See `core::string_view::compare`]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *pos1*
| `size_type`

| *n1*
| `size_type`

| *s*
| ``

| *n2*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_of-0ab]

= Function string_view_base::find_first_of

pass:v,q[Return the position of the first match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L567[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *str*
| `string_view`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_of-04]

= Function string_view_base::find_first_of

pass:v,q[Return the position of the first match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L577[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_of-0af]

= Function string_view_base::find_first_of

pass:v,q[Return the position of the first match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L587[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

| *n*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_of-08]

= Function string_view_base::find_first_of

pass:v,q[Return the position of the first match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L597[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-contains-08]

= Function string_view_base::contains

pass:v,q[Return true if matching characters are found]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L735[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
contains(string_view sv) const noexcept;
----

== Description

pass:v,q[See `core::string_view::contains`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *sv*
| `string_view`

|===




[#boost-urls-grammar-string_view_base-contains-04]

= Function string_view_base::contains

pass:v,q[Return true if matching characters are found]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L744[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
contains(char c) const noexcept;
----

== Description

pass:v,q[See `core::string_view::contains`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

|===




[#boost-urls-grammar-string_view_base-contains-03]

= Function string_view_base::contains

pass:v,q[Return true if matching characters are found]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L753[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
bool
contains(const char* s) const noexcept;
----

== Description

pass:v,q[See `core::string_view::contains`]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *s*
| ``

|===




[#boost-urls-grammar-string_view_base-find_last_of-00]

= Function string_view_base::find_last_of

pass:v,q[Return the position of the last match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L609[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *str*
| `string_view`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_last_of-0c]

= Function string_view_base::find_last_of

pass:v,q[Return the position of the last match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L619[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_last_of-02]

= Function string_view_base::find_last_of

pass:v,q[Return the position of the last match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L629[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

| *n*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_last_of-08]

= Function string_view_base::find_last_of

pass:v,q[Return the position of the last match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L639[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_not_of-0e]

= Function string_view_base::find_first_not_of

pass:v,q[Return the position of the first non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L651[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *str*
| `string_view`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_not_of-02]

= Function string_view_base::find_first_not_of

pass:v,q[Return the position of the first non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L661[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_not_of-0a]

= Function string_view_base::find_first_not_of

pass:v,q[Return the position of the first non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L671[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

| *n*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_first_not_of-0c]

= Function string_view_base::find_first_not_of

pass:v,q[Return the position of the first non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L681[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_first_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = 0) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_first_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_last_not_of-03]

= Function string_view_base::find_last_not_of

pass:v,q[Return the position of the last non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L693[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    string_view str,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *str*
| `string_view`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_last_not_of-0d]

= Function string_view_base::find_last_not_of

pass:v,q[Return the position of the last non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L703[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    char c,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *c*
| `char`

| *pos*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_last_not_of-01]

= Function string_view_base::find_last_not_of

pass:v,q[Return the position of the last non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L713[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] n) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

| *n*
| `size_type`

|===




[#boost-urls-grammar-string_view_base-find_last_not_of-06]

= Function string_view_base::find_last_not_of

pass:v,q[Return the position of the last non-match]


== Synopsis

Declared in header `</boost/url/grammar/string_view_base.hpp#L723[boost/url/grammar/string_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-string_view_base-size_type[size_type]
find_last_not_of(
    const char* s,
    xref:boost-urls-grammar-string_view_base-size_type[size_type] pos = core::string_view::npos) const noexcept;
----

== Description

pass:v,q[See `core::string_view::find_last_not_of`]



== Return Value

* `size_type` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *pos*
| `size_type`

|===




[#boost-urls-grammar-ref-07]

= Function ref



== Synopsis

Declared in header `</boost/url/grammar/charset.hpp#L197[boost/url/grammar/charset.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
constexpr
enable_if<is_charset<CharSet>::value && !std::is_same<CharSet, detail::charset_ref<CharSet>>::value, charset_ref<CharSet>>::type
ref(const CharSet& cs) noexcept;
----


[#boost-urls-grammar-ref-03]

= Function ref



== Synopsis

Declared in header `</boost/url/grammar/parse.hpp#L113[boost/url/grammar/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
constexpr
enable_if<is_rule<Rule>::value && !std::is_same<Rule, detail::rule_ref<Rule>>::value, rule_ref<Rule>>::type
ref(const Rule& r) noexcept;
----


[#boost-urls-grammar-ref-01]

= Function ref



== Synopsis

Declared in header `</boost/url/grammar/parse.hpp#L133[boost/url/grammar/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
void
ref() = delete;
----


[#boost-urls-grammar-parse-06]

= Function parse

pass:v,q[Parse a character buffer using a rule]


== Synopsis

Declared in header `</boost/url/grammar/parse.hpp#L41[boost/url/grammar/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R>
result<Rule::value_type>
parse(
    const char*& it,
    const char* end,
    const Rule& r);
----


[#boost-urls-grammar-parse-02]

= Function parse

pass:v,q[Parse a character buffer using a rule]


== Synopsis

Declared in header `</boost/url/grammar/parse.hpp#L65[boost/url/grammar/parse.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R>
result<Rule::value_type>
parse(
    string_view s,
    const Rule& r);
----

== Description

pass:v,q[This function parses a complete string into] pass:v,q[the specified sequence of rules. If the]
pass:v,q[string is not completely consumed, an]
pass:v,q[error is returned instead.]



== Return Value

* `result` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

| *r*
| ``

|===




[#boost-urls-grammar-ci_is_equal-0a]

= Function ci_is_equal



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L173[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class String0,
    class String1>
enable_if<!std::is_convertible<String0, core::string_view>::value || !std::is_convertible<String1, core::string_view>::value, bool>::type
ci_is_equal(
    const String0& s0,
    const String1& s1);
----


[#boost-urls-grammar-ci_is_equal-0b]

= Function ci_is_equal



== Synopsis

Declared in header `</boost/url/grammar/ci_string.hpp#L192[boost/url/grammar/ci_string.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
ci_is_equal(
    string_view s0,
    string_view s1) noexcept;
----


[#boost-urls-grammar-variant_rule-0b]

= Function variant_rule



== Synopsis

Declared in header `</boost/url/grammar/variant_rule.hpp#L94[boost/url/grammar/variant_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0_,
    class... Rn_>
constexpr
xref:boost-urls-grammar-variant_rule_t[variant_rule_t]<R0_, Rn_...>
variant_rule(
    const R0_& r0,
    const Rn_&... rn) noexcept;
----


[#boost-urls-grammar-variant_rule-0d]

= Function variant_rule



== Synopsis

Declared in header `</boost/url/grammar/variant_rule.hpp#L117[boost/url/grammar/variant_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0,
    class... Rn>
constexpr
xref:boost-urls-grammar-variant_rule_t[variant_rule_t]<R0, Rn...>
variant_rule(
    const R0& r0,
    const Rn&... rn) noexcept;
----


[#boost-urls-grammar-delim_rule-02]

= Function delim_rule



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L81[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
xref:boost-urls-grammar-ch_delim_rule[ch_delim_rule]
delim_rule(char ch) noexcept;
----


[#boost-urls-grammar-delim_rule-0a]

= Function delim_rule



== Synopsis

Declared in header `</boost/url/grammar/delim_rule.hpp#L164[boost/url/grammar/delim_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
constexpr
enable_if<!std::is_convertible<CharSet, char>::value, xref:boost-urls-grammar-cs_delim_rule[cs_delim_rule]<CharSet>>::type
delim_rule(const CharSet& cs) noexcept;
----


[#boost-urls-grammar-optional_rule-0c]

= Function optional_rule



== Synopsis

Declared in header `</boost/url/grammar/optional_rule.hpp#L77[boost/url/grammar/optional_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class R_>
constexpr
xref:boost-urls-grammar-optional_rule_t[optional_rule_t]<R_>
optional_rule(const R_& r);
----


[#boost-urls-grammar-optional_rule-03]

= Function optional_rule



== Synopsis

Declared in header `</boost/url/grammar/optional_rule.hpp#L96[boost/url/grammar/optional_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
constexpr
xref:boost-urls-grammar-optional_rule_t[optional_rule_t]<Rule>
optional_rule(const Rule& r);
----


[#boost-urls-grammar-tuple_rule-00]

= Function tuple_rule



== Synopsis

Declared in header `</boost/url/grammar/tuple_rule.hpp#L109[boost/url/grammar/tuple_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0_,
    class... Rn_>
constexpr
xref:boost-urls-grammar-tuple_rule_t[tuple_rule_t]<R0_, Rn_...>
tuple_rule(
    const R0_& r0,
    const Rn_&... rn) noexcept;
----


[#boost-urls-grammar-tuple_rule-0e]

= Function tuple_rule



== Synopsis

Declared in header `</boost/url/grammar/tuple_rule.hpp#L138[boost/url/grammar/tuple_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class R0,
    class... Rn>
constexpr
xref:boost-urls-grammar-tuple_rule_t[tuple_rule_t]<R0, Rn...>
tuple_rule(
    const R0& r0,
    const Rn&... rn) noexcept;
----


[#boost-urls-grammar-recycled_ptr-operator_assign-0b]

= Function recycled_ptr::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L367[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&
operator=(xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&& other) noexcept;
----

== Description

pass:v,q[If `other` references an object,] pass:v,q[ownership is transferred including]
pass:v,q[a reference to the recycle bin. After]
pass:v,q[the move, the moved-from object is empty.]

=== Effects
[,cpp]
----
this->release()
----

=== Postconditions
[,cpp]
----
&this->bin() == &other->bin()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-recycled_ptr-operator_assign-09]

= Function recycled_ptr::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L394[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&
operator=(const xref:boost-urls-grammar-recycled_ptr[recycled_ptr]& other) noexcept;
----

== Description

pass:v,q[If `other` references an object,] pass:v,q[this acquires shared ownership and]
pass:v,q[references the same recycle bin as]
pass:v,q[`other`. The previous object if any]
pass:v,q[is released.]

=== Effects
[,cpp]
----
this->release()
----

=== Postconditions
[,cpp]
----
&this->bin() == &other->bin() && this->get() == other.get()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-recycled_ptr-2constructor-08]

= Function recycled_ptr::recycled_ptr

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L209[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(xref:boost-urls-grammar-recycled[recycled]<T>& bin);
----

== Description

pass:v,q[Upon construction, this acquires] pass:v,q[exclusive access to an object of type]
pass:v,q[`T` which is either recycled from the]
pass:v,q[specified bin, or newly allocated.]
pass:v,q[The object is in an unknown but]
pass:v,q[valid state.]

=== Example
[,cpp]
----
static recycled< std::string > bin;

recycled_ptr< std::string > ps( bin );

// Put the string into a known state
ps->clear();
----

=== Postconditions
[,cpp]
----
&this->bin() == &bin && ! this->empty()
----



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *bin*
| ``

|===




[#boost-urls-grammar-recycled_ptr-2constructor-0ac]

= Function recycled_ptr::recycled_ptr

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L243[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(
    xref:boost-urls-grammar-recycled[recycled]<T>& bin,
    nullptr_t) noexcept;
----

== Description

pass:v,q[After construction, this is empty and] pass:v,q[refers to the specified recycle bin.]

=== Example
[,cpp]
----
static recycled< std::string > bin;

recycled_ptr< std::string > ps( bin, nullptr );

// Acquire a string and put it into a known state
ps->acquire();
ps->clear();
----

=== Postconditions
[,cpp]
----
&this->bin() == &bin && this->empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *bin*
| ``

| **
| `nullptr_t`

|===




[#boost-urls-grammar-recycled_ptr-2constructor-056]

= Function recycled_ptr::recycled_ptr

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L272[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr();
----

== Description

pass:v,q[Upon construction, this acquires] pass:v,q[exclusive access to an object of type]
pass:v,q[`T` which is either recycled from a]
pass:v,q[global recycle bin, or newly allocated.]
pass:v,q[The object is in an unknown but]
pass:v,q[valid state.]

=== Example
[,cpp]
----
recycled_ptr< std::string > ps;

// Put the string into a known state
ps->clear();
----

=== Postconditions
[,cpp]
----
&this->bin() != nullptr && ! this->empty()
----



== Return Value

* `void` 





[#boost-urls-grammar-recycled_ptr-2constructor-05e]

= Function recycled_ptr::recycled_ptr

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L301[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(nullptr_t) noexcept;
----

== Description

pass:v,q[After construction, this is empty] pass:v,q[and refers to a global recycle bin.]

=== Example
[,cpp]
----
recycled_ptr< std::string > ps( nullptr );

// Acquire a string and put it into a known state
ps->acquire();
ps->clear();
----

=== Postconditions
[,cpp]
----
&this->bin() != nullptr && this->empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| **
| `nullptr_t`

|===




[#boost-urls-grammar-recycled_ptr-2constructor-0ab]

= Function recycled_ptr::recycled_ptr

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L322[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(const xref:boost-urls-grammar-recycled_ptr[recycled_ptr]& other) noexcept;
----

== Description

pass:v,q[If `other` references an object, the] pass:v,q[newly constructed pointer acquires]
pass:v,q[shared ownership. Otherwise this is]
pass:v,q[empty. The new pointer references]
pass:v,q[the same recycle bin as `other`.]

=== Postconditions
[,cpp]
----
&this->bin() == &other->bin() && this->get() == other.get()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-recycled_ptr-2constructor-0f]

= Function recycled_ptr::recycled_ptr

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/recycled.hpp#L342[boost/url/grammar/recycled.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
recycled_ptr(xref:boost-urls-grammar-recycled_ptr[recycled_ptr]&& other) noexcept;
----

== Description

pass:v,q[If `other` references an object,] pass:v,q[ownership is transferred including]
pass:v,q[a reference to the recycle bin. After]
pass:v,q[the move, the moved-from object is empty.]

=== Postconditions
[,cpp]
----
&this->bin() == &other->bin() && ! this->empty() && other.empty()
----

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-range-iterator-2constructor-05]

= Function range::iterator::iterator



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L373[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator() = default;
----


[#boost-urls-grammar-range-iterator-2constructor-03]

= Function range::iterator::iterator



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L374[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator(const xref:boost-urls-grammar-range-iterator[iterator]&) = default;
----


[#boost-urls-grammar-range-iterator-operator_inc-06]

= Function range::iterator::operator++



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L403[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator[iterator]&
operator++() noexcept;
----


[#boost-urls-grammar-range-iterator-operator_inc-05]

= Function range::iterator::operator++



== Synopsis

Declared in header `</boost/url/grammar/impl/range_rule.hpp#L417[boost/url/grammar/impl/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range-iterator[iterator]
operator++(int) noexcept;
----


[#boost-urls-grammar-range-2constructor-01e]

= Function range::range

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L175[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
range() noexcept;
----

== Description

pass:v,q[Default-constructed ranges have] pass:v,q[zero elements.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-grammar-range-2constructor-08]

= Function range::range

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L191[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
range(xref:boost-urls-grammar-range[range]&& other) noexcept;
----

== Description

pass:v,q[The new range references the] pass:v,q[same underlying character buffer.]
pass:v,q[Ownership is not transferred; the]
pass:v,q[caller is responsible for ensuring]
pass:v,q[that the lifetime of the buffer]
pass:v,q[extends until it is no longer]
pass:v,q[referenced. The moved-from object]
pass:v,q[becomes as if default-constructed.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-range-2constructor-01b]

= Function range::range

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L206[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
range(const xref:boost-urls-grammar-range[range]& other) noexcept;
----

== Description

pass:v,q[The copy references the same] pass:v,q[underlying character buffer.] pass:v,q[Ownership is not transferred; the]
pass:v,q[caller is responsible for ensuring]
pass:v,q[that the lifetime of the buffer]
pass:v,q[extends until it is no longer]
pass:v,q[referenced.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-range-operator_assign-08]

= Function range::operator=

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L221[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range[range]&
operator=(xref:boost-urls-grammar-range[range]&& other) noexcept;
----

== Description

pass:v,q[After the move, this references the] pass:v,q[same underlying character buffer. Ownership]
pass:v,q[is not transferred; the caller is responsible]
pass:v,q[for ensuring that the lifetime of the buffer]
pass:v,q[extends until it is no longer referenced.]
pass:v,q[The moved-from object becomes as if]
pass:v,q[default-constructed.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-range-operator_assign-0e]

= Function range::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L237[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-grammar-range[range]&
operator=(const xref:boost-urls-grammar-range[range]& other) noexcept;
----

== Description

pass:v,q[The copy references the same] pass:v,q[underlying character buffer.] pass:v,q[Ownership is not transferred; the]
pass:v,q[caller is responsible for ensuring]
pass:v,q[that the lifetime of the buffer]
pass:v,q[extends until it is no longer]
pass:v,q[referenced.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-grammar-range_rule-09]

= Function range_rule



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L396[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class Rule>
constexpr
xref:boost-urls-grammar-range_rule_t-09[range_rule_t]<Rule>
range_rule(
    const Rule& next,
    size_t N = 0,
    size_t M = std::size_t(-1)) noexcept;
----


[#boost-urls-grammar-range_rule-02]

= Function range_rule



== Synopsis

Declared in header `</boost/url/grammar/range_rule.hpp#L554[boost/url/grammar/range_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class Rule1,
    class Rule2>
constexpr
enable_if<!std::is_integral<Rule2>::value, xref:boost-urls-grammar-range_rule_t-09[range_rule_t]<Rule1, Rule2>>::type
range_rule(
    const Rule1& first,
    const Rule2& next,
    size_t N = 0,
    size_t M = std::size_t(-1)) noexcept;
----


[#boost-urls-string_token-arg-2constructor-01]

= Function arg::arg



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L72[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
arg() = default;
----


[#boost-urls-string_token-arg-2constructor-0c]

= Function arg::arg



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L73[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
arg(xref:boost-urls-string_token-arg[arg]&&) = default;
----


[#boost-urls-string_token-arg-2constructor-05]

= Function arg::arg



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L74[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
arg(const xref:boost-urls-string_token-arg[arg]&) = delete;
----


[#boost-urls-string_token-arg-operator_assign-0f]

= Function arg::operator=



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L75[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-arg[arg]&
operator=(xref:boost-urls-string_token-arg[arg]&&) = delete;
----


[#boost-urls-string_token-arg-operator_assign-01]

= Function arg::operator=



== Synopsis

Declared in header `</boost/url/grammar/string_token.hpp#L76[boost/url/grammar/string_token.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-string_token-arg[arg]&
operator=(const xref:boost-urls-string_token-arg[arg]&) = delete;
----


[#boost-urls-decode_view-iterator-2constructor-05]

= Function decode_view::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L58[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator() = default;
----


[#boost-urls-decode_view-iterator-2constructor-07]

= Function decode_view::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L60[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-decode_view-iterator[iterator]&) = default;
----


[#boost-urls-decode_view-iterator-operator_inc-0a]

= Function decode_view::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L69[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]&
operator++() noexcept;
----


[#boost-urls-decode_view-iterator-operator_inc-07]

= Function decode_view::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L92[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]
operator++(int) noexcept;
----


[#boost-urls-decode_view-iterator-operator_dec-04]

= Function decode_view::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L80[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]&
operator--() noexcept;
----


[#boost-urls-decode_view-iterator-operator_dec-0a]

= Function decode_view::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/decode_view.hpp#L100[boost/url/impl/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-decode_view-iterator[iterator]
operator--(int) noexcept;
----


[#boost-urls-decode_view-2constructor-07]

= Function decode_view::decode_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L174[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
decode_view() noexcept = default;
----

== Description

pass:v,q[Default-constructed views represent] pass:v,q[empty strings.]

=== Example
[,cpp]
----
decode_view ds;
----

=== Postconditions
[,cpp]
----
this->empty() == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-decode_view-2constructor-03]

= Function decode_view::decode_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L209[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
decode_view(
    xref:boost-urls-pct_string_view[pct_string_view] s,
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {}) noexcept;
----

== Description

pass:v,q[This constructs a view from the character] pass:v,q[buffer `s`, which must remain valid and]
pass:v,q[unmodified until the view is no longer]
pass:v,q[accessed.]

=== Example
[,cpp]
----
decode_view ds( "Program%20Files" );
----

=== Postconditions
[,cpp]
----
this->encoded() == s
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `pct_string_view`

| *opt*
| `encoding_opts`

|===




[#boost-urls-decode_view-starts_with-01]

= Function decode_view::starts_with

pass:v,q[Checks if the string begins with the given prefix]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L357[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
starts_with(string_view s) const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "Program%20Files" ).starts_with("Program") );
----

=== Complexity
pass:v,q[Linear.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-decode_view-starts_with-0b]

= Function decode_view::starts_with

pass:v,q[Checks if the string begins with the given prefix]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L391[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
starts_with(char ch) const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "Program%20Files" ).starts_with('P') );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *ch*
| `char`

|===




[#boost-urls-decode_view-ends_with-04]

= Function decode_view::ends_with

pass:v,q[Checks if the string ends with the given prefix]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L374[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
ends_with(string_view s) const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "Program%20Files" ).ends_with("Files") );
----

=== Complexity
pass:v,q[Linear.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-decode_view-ends_with-0d]

= Function decode_view::ends_with

pass:v,q[Checks if the string ends with the given prefix]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L408[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
ends_with(char ch) const noexcept;
----

== Description


=== Example
[,cpp]
----
assert( decode_view( "Program%20Files" ).ends_with('s') );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *ch*
| `char`

|===




[#boost-urls-decode_view-compare-02]

= Function decode_view::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L511[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
int
compare(string_view other) const noexcept;
----

== Description

pass:v,q[The length of the sequences to compare is the smaller of] pass:v,q[`size()` and `other.size()`.]
pass:v,q[The function compares the two strings as if by calling]
pass:v,q[`char_traits]
pass:v,q[<char]
pass:v,q[>::compare(to_string().data(), v.data(), rlen)`.]
pass:v,q[This means the comparison is performed with]
pass:v,q[percent-decoding applied to the current string.]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *other*
| `string_view`

|===




[#boost-urls-decode_view-compare-01]

= Function decode_view::compare

pass:v,q[Return the result of comparing to another string]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L532[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
int
compare(xref:boost-urls-decode_view[decode_view] other) const noexcept;
----

== Description

pass:v,q[The length of the sequences to compare is the smaller of] pass:v,q[`size()` and `other.size()`.]
pass:v,q[The function compares the two strings as if by calling]
pass:v,q[`char_traits]
pass:v,q[<char]
pass:v,q[>::compare(to_string().data(), v.to_string().data(), rlen)`.]
pass:v,q[This means the comparison is performed with]
pass:v,q[percent-decoding applied to the current string.]



== Return Value

* `int` 


== Parameters

|===
| Name | Type 

| *other*
| `decode_view`

|===




[#boost-urls-pct_string_view-2constructor-00]

= Function pct_string_view::pct_string_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L117[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
pct_string_view() = default;
----

== Description

pass:v,q[Default constructed string are empty.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-pct_string_view-2constructor-07]

= Function pct_string_view::pct_string_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L138[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
pct_string_view(const xref:boost-urls-pct_string_view[pct_string_view]& other) = default;
----

== Description

pass:v,q[The copy references the same] pass:v,q[underlying character buffer.] pass:v,q[Ownership is not transferred.]

=== Postconditions
[,cpp]
----
this->data() == other.data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== other The string to copy.



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-pct_string_view-2constructor-0c]

= Function pct_string_view::pct_string_view



== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L176[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class String,
    class = enable_if<std::is_convertible<String, core::string_view>::value>::type>
pct_string_view(const String& s);
----


[#boost-urls-pct_string_view-2constructor-0f]

= Function pct_string_view::pct_string_view

pass:v,q[Constructor (deleted)]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L185[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
pct_string_view(nullptr_t) = delete;
----


[#boost-urls-pct_string_view-2constructor-06]

= Function pct_string_view::pct_string_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L210[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
pct_string_view(
    const char* s,
    size_t len);
----

== Description

pass:v,q[The newly constructed string references] pass:v,q[the specified character buffer. Ownership]
pass:v,q[is not transferred.]

=== Postconditions
[,cpp]
----
this->data() == s && this->size() == len
----

=== Complexity
pass:v,q[Linear in `len`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| ``

| *len*
| `size_t`

|===




[#boost-urls-pct_string_view-2constructor-0d]

= Function pct_string_view::pct_string_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/pct_string_view.hpp#L241[boost/url/pct_string_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
pct_string_view(string_view s);
----

== Description

pass:v,q[The newly constructed string references] pass:v,q[the specified character buffer. Ownership]
pass:v,q[is not transferred.]

=== Postconditions
[,cpp]
----
this->data() == s.data() && this->size() == s.size()
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-encode-09]

= Function encode

pass:v,q[Apply percent-encoding to a string]


== Synopsis

Declared in header `</boost/url/encode.hpp#L118[boost/url/encode.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
size_t
encode(
    char* dest,
    size_t size,
    string_view s,
    const CharSet& unreserved,
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {});
----

== Description

pass:v,q[This function applies percent-encoding] pass:v,q[to the string using the given options and]
pass:v,q[character set. The destination buffer]
pass:v,q[provided by the caller is used to store]
pass:v,q[the result, which may be truncated if]
pass:v,q[there is insufficient space.]

=== Example
[,cpp]
----
char buf[100];
assert( encode( buf, sizeof(buf), "Program Files", pchars ) == 15 );
----

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-2.1[2.1. Percent-Encoding (rfc3986)]



== Return Value

* `size_t` 


== Parameters

|===
| Name | Type 

| *dest*
| ``

| *size*
| `size_t`

| *s*
| `string_view`

| *unreserved*
| ``

| *opt*
| `encoding_opts`

|===




[#boost-urls-encode-04]

= Function encode

pass:v,q[Return a percent-encoded string]


== Synopsis

Declared in header `</boost/url/encode.hpp#L184[boost/url/encode.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class StringToken = xref:boost-urls-string_token[string_token]::xref:boost-urls-string_token-return_string[return_string],
    class CharSet>
StringToken::result_type
encode(
    string_view s,
    const CharSet& unreserved,
    xref:boost-urls-encoding_opts[encoding_opts] opt = = {},
    StringToken&& token) noexcept;
----

== Description

pass:v,q[This function applies percent-encoding] pass:v,q[to the string using the given options and]
pass:v,q[character set, and returns the result as]
pass:v,q[a string when called with default arguments.]

=== Example
[,cpp]
----
encoding_opts opt;
opt.space_as_plus = true;
std::string s = encode( "My Stuff", opt, pchars );

assert( s == "My+Stuff" );
----

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-2.1[2.1. Percent-Encoding (rfc3986)]



== Return Value

* `result_type` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

| *unreserved*
| ``

| *opt*
| `encoding_opts`

| *token*
| ``

|===




[#boost-urls-operator_lt-0b]

= Function operator<



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L597[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-operator_lt-0a]

= Function operator<

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1286[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *a0*
| ``

| *a1*
| ``

|===




[#boost-urls-operator_lt-04]

= Function operator<

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2533[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.b.com/index.htm" );
assert( u0 < u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) <
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *u0*
| ``

| *u1*
| ``

|===




[#boost-urls-operator_le-06]

= Function operator<=



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L606[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator<=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-operator_le-01]

= Function operator<=

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1306[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *a0*
| ``

| *a1*
| ``

|===




[#boost-urls-operator_le-0a]

= Function operator<=

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2593[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator<=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.b.com/index.htm" );
url_view u1( "http://www.b.com/index.htm" );
assert( u0 <= u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) <=
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *u0*
| ``

| *u1*
| ``

|===




[#boost-urls-operator_eq-0e]

= Function operator==



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L579[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator==(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-operator_eq-0f2]

= Function operator==

pass:v,q[Return true if two addresses are equal]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L243[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-ipv4_address[ipv4_address]& a1,
    const xref:boost-urls-ipv4_address[ipv4_address]& a2) noexcept;
----


[#boost-urls-operator_eq-0fd]

= Function operator==

pass:v,q[Return true if two addresses are equal]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L293[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-ipv6_address[ipv6_address]& a1,
    const xref:boost-urls-ipv6_address[ipv6_address]& a2) noexcept;
----


[#boost-urls-operator_eq-09]

= Function operator==

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1246[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *a0*
| ``

| *a1*
| ``

|===




[#boost-urls-operator_eq-0d]

= Function operator==



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L97[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it0,
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it1) noexcept;
----


[#boost-urls-operator_eq-01]

= Function operator==

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2413[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator==(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.a.com/index.htm" );
assert( u0 == u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) ==
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *u0*
| ``

| *u1*
| ``

|===




[#boost-urls-operator_not_eq-03b]

= Function operator!=



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L588[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator!=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-operator_not_eq-02]

= Function operator!=

pass:v,q[Return true if two addresses are not equal]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L254[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-ipv4_address[ipv4_address]& a1,
    const xref:boost-urls-ipv4_address[ipv4_address]& a2) noexcept;
----


[#boost-urls-operator_not_eq-07]

= Function operator!=

pass:v,q[Return true if two addresses are not equal]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L304[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-ipv6_address[ipv6_address]& a1,
    const xref:boost-urls-ipv6_address[ipv6_address]& a2) noexcept;
----


[#boost-urls-operator_not_eq-037]

= Function operator!=

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1266[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *a0*
| ``

| *a1*
| ``

|===




[#boost-urls-operator_not_eq-0f]

= Function operator!=



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L106[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it0,
    const xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]& it1) noexcept;
----


[#boost-urls-operator_not_eq-04]

= Function operator!=

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2473[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator!=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.b.com/index.htm" );
assert( u0 != u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) !=
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *u0*
| ``

| *u1*
| ``

|===




[#boost-urls-operator_gt-02]

= Function operator>



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L615[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-operator_gt-08]

= Function operator>

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1326[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *a0*
| ``

| *a1*
| ``

|===




[#boost-urls-operator_gt-09]

= Function operator>

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2653[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.b.com/index.htm" );
url_view u1( "http://www.a.com/index.htm" );
assert( u0 > u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) >
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *u0*
| ``

| *u1*
| ``

|===




[#boost-urls-operator_ge-01]

= Function operator>=



== Synopsis

Declared in header `</boost/url/decode_view.hpp#L624[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class S0,
    class S1>
constexpr
enable_if<is_match<S0, S1>::value, bool>::type
operator>=(
    const S0& s0,
    const S1& s1) noexcept;
----


[#boost-urls-operator_ge-08]

= Function operator>=

pass:v,q[Return the result of comparing two authorities] pass:v,q[The authorities are compared component]
pass:v,q[by component as if they were first]
pass:v,q[normalized.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1346[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>=(
    const xref:boost-urls-authority_view[authority_view]& a0,
    const xref:boost-urls-authority_view[authority_view]& a1) noexcept;
----

== Description


=== Complexity
pass:v,q[Linear in `min( a0.size(), a1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *a0*
| ``

| *a1*
| ``

|===




[#boost-urls-operator_ge-00]

= Function operator>=

pass:v,q[Return the result of comparing two URLs]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2713[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
bool
operator>=(
    const xref:boost-urls-url_view_base[url_view_base]& u0,
    const xref:boost-urls-url_view_base[url_view_base]& u1) noexcept;
----

== Description

pass:v,q[The URLs are compared component by] pass:v,q[component as if they were first]
pass:v,q[normalized.]

=== Example
[,cpp]
----
url_view u0( "http://www.a.com/index.htm" );
url_view u1( "http://www.a.com/index.htm" );
assert( u0 >= u1 );
----

=== Effects
[,cpp]
----
url a(u0);
a.normalize();
url b(u1);
b.normalize();
return std::make_tuple(
           a.scheme(),
           a.user(),
           a.password(),
           a.host(),
           a.port(),
           a.path(),
           a.query(),
           a.fragment()) >=
       std::make_tuple(
           b.scheme(),
           b.user(),
           b.password(),
           b.host(),
           b.port(),
           b.path(),
           b.query(),
           b.fragment());
----

=== Complexity
pass:v,q[Linear in `min( u0.size(), u1.size() )`]

=== Exception Safety
pass:v,q[Throws nothing]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-6.2.2[6.2.2 Syntax-Based Normalization (rfc3986)]



== Return Value

* `bool` 


== Parameters

|===
| Name | Type 

| *u0*
| ``

| *u1*
| ``

|===




[#boost-urls-param_pct_view-2constructor-00]

= Function param_pct_view::param_pct_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L689[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
param_pct_view() = default;
----

== Description

pass:v,q[Default constructed query parameters] pass:v,q[have an empty key and no value.]

=== Example
[,cpp]
----
param_pct_view qp;
----

=== Postconditions
[,cpp]
----
this->key == "" && this->value == "" && this->has_value == false
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-param_pct_view-2constructor-0e]

= Function param_pct_view::param_pct_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L725[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param_pct_view(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-pct_string_view[pct_string_view] value) noexcept;
----

== Description

pass:v,q[This constructs a parameter with a key] pass:v,q[and value, which may both contain percent]
pass:v,q[escapes.]
pass:v,q[The new key and value reference]
pass:v,q[the same corresponding underlying]
pass:v,q[character buffers.]
pass:v,q[Ownership of the buffers is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the assigned buffers remain valid until]
pass:v,q[they are no longer referenced.]

=== Example
[,cpp]
----
param_pct_view qp( "key", "value" );
----

=== Postconditions
[,cpp]
----
this->key.data() == key.data() && this->value.data() == value.data() && this->has_value == true
----

=== Complexity
pass:v,q[Linear in `key.size() + value.size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *value*
| `pct_string_view`

|===




[#boost-urls-param_pct_view-2constructor-05]

= Function param_pct_view::param_pct_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L776[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class OptionalString>
param_pct_view(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    const OptionalString& value);
----

== Description

pass:v,q[This constructs a parameter with a key] pass:v,q[and optional value, which may both]
pass:v,q[contain percent escapes.]
pass:v,q[The new key and value reference]
pass:v,q[the same corresponding underlying]
pass:v,q[character buffers.]
pass:v,q[Ownership of the buffers is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the assigned buffers remain valid until]
pass:v,q[they are no longer referenced.]

=== Example
[,cpp]
----
param_pct_view qp( "key", optional<core::string_view>("value") );
----

=== Postconditions
[,cpp]
----
this->key.data() == key.data() && this->value->data() == value->data() && this->has_value == true
----

=== Complexity
pass:v,q[Linear in `key.size() + value->size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *value*
| ``

|===




[#boost-urls-param_pct_view-2constructor-03]

= Function param_pct_view::param_pct_view

pass:v,q[Construction]


== Synopsis

Declared in header `</boost/url/param.hpp#L816[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param_pct_view(const xref:boost-urls-param_view[param_view]& p);
----

== Description

pass:v,q[This converts a param which may] pass:v,q[contain unvalidated percent-escapes into]
pass:v,q[a param whose key and value are]
pass:v,q[guaranteed to contain strings with no]
pass:v,q[invalid percent-escapes, otherwise]
pass:v,q[an exception is thrown.]
pass:v,q[The new key and value reference]
pass:v,q[the same corresponding underlying]
pass:v,q[character buffers.]
pass:v,q[Ownership of the buffers is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the assigned buffers remain valid until]
pass:v,q[they are no longer referenced.]

=== Example
[,cpp]
----
param_pct_view qp( param_view( "key", "value" ) );
----

=== Complexity
pass:v,q[Linear in `key.size() + value.size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *p*
| ``

|===




[#boost-urls-param_pct_view-2constructor-02]

= Function param_pct_view::param_pct_view



== Synopsis

Declared in header `</boost/url/param.hpp#L866[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param_pct_view(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-pct_string_view[pct_string_view] value,
    bool has_value) noexcept;
----


[#boost-urls-param_view-2constructor-07a]

= Function param_view::param_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L455[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
param_view() = default;
----

== Description

pass:v,q[Default constructed query parameters] pass:v,q[have an empty key and no value.]

=== Example
[,cpp]
----
param_view qp;
----

=== Postconditions
[,cpp]
----
this->key == "" && this->value == "" && this->has_value == false
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-param_view-2constructor-01]

= Function param_view::param_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L494[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class OptionalString>
param_view(
    string_view key,
    const OptionalString& value) noexcept;
----

== Description

pass:v,q[This constructs a parameter with a key] pass:v,q[and value.] pass:v,q[No validation is performed on the strings.]
pass:v,q[The new key and value reference]
pass:v,q[the same corresponding underlying]
pass:v,q[character buffers.]
pass:v,q[Ownership of the buffers is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the assigned buffers remain valid until]
pass:v,q[they are no longer referenced.]

=== Example
[,cpp]
----
param_view qp( "key", "value" );
----

=== Postconditions
[,cpp]
----
this->key.data() == key.data() && this->value.data() == value.data() && this->has_value == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *value*
| ``

|===




[#boost-urls-param_view-2constructor-07e]

= Function param_view::param_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L531[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param_view(const xref:boost-urls-param[param]& other) noexcept;
----

== Description

pass:v,q[This function constructs a param] pass:v,q[which references the character buffers]
pass:v,q[representing the key and value in another]
pass:v,q[container.]
pass:v,q[Ownership of the buffers is not transferred;]
pass:v,q[the caller is responsible for ensuring that]
pass:v,q[the assigned buffers remain valid until]
pass:v,q[they are no longer referenced.]

=== Example
[,cpp]
----
param qp( "key", "value" );
param_view qpv( qp );
----

=== Postconditions
[,cpp]
----
this->key == key && this->value == value && this->has_value == other.has_value
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-param_view-2constructor-03]

= Function param_view::param_view



== Synopsis

Declared in header `</boost/url/param.hpp#L570[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param_view(
    string_view key_,
    string_view value_,
    bool has_value_) noexcept;
----


[#boost-urls-param-2constructor-09]

= Function param::param

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L124[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param() = default;
----

== Description

pass:v,q[Default constructed query parameters] pass:v,q[have an empty key and no value.]

=== Example
[,cpp]
----
param qp;
----

=== Postconditions
[,cpp]
----
this->key == "" && this->value == "" && this->has_value == false
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-param-2constructor-07]

= Function param::param

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L142[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param(xref:boost-urls-param[param]&& other) noexcept;
----

== Description

pass:v,q[Upon construction, this acquires] pass:v,q[ownership of the members of other]
pass:v,q[via move construction. The moved]
pass:v,q[from object is as if default]
pass:v,q[constructed.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== other The object to construct from.



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-param-2constructor-0d]

= Function param::param

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L173[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param(const xref:boost-urls-param[param]& other) = default;
----

== Description

pass:v,q[Upon construction, this becomes a copy] pass:v,q[of `other`.]

=== Postconditions
[,cpp]
----
this->key == other.key && this->value == other.value && this->has_value == other.has_value
----

=== Complexity
pass:v,q[Linear in `other.key.size() + other.value.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== other The object to construct from.



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-param-2constructor-0b]

= Function param::param

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/param.hpp#L278[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class OptionalString>
param(
    string_view key,
    const OptionalString& value);
----

== Description

pass:v,q[This constructs a parameter with a key] pass:v,q[and value.]
pass:v,q[No validation is performed on the strings.]
pass:v,q[Ownership of the key and value is acquired]
pass:v,q[by making copies.]

=== Example
[,cpp]
----
param qp( "key", "value" );
----
[,cpp]
----
param qp( "key", optional<core::string_view>("value") );
----
[,cpp]
----
param qp( "key", boost::none );
----
[,cpp]
----
param qp( "key", nullptr );
----
[,cpp]
----
param qp( "key", no_value );
----

=== Postconditions
[,cpp]
----
this->key == key && this->value == value && this->has_value == true
----

=== Complexity
pass:v,q[Linear in `key.size() + value.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *value*
| ``

|===




[#boost-urls-param-2constructor-0a]

= Function param::param



== Synopsis

Declared in header `</boost/url/param.hpp#L336[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
param(
    string_view key,
    string_view value,
    bool has_value) noexcept;
----


[#boost-urls-param-operator_assign-0b]

= Function param::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/param.hpp#L191[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(xref:boost-urls-param[param]&& other) noexcept;
----

== Description

pass:v,q[Upon assignment, this acquires] pass:v,q[ownership of the members of other]
pass:v,q[via move assignment. The moved]
pass:v,q[from object is as if default]
pass:v,q[constructed.]

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== other The object to assign from.



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-param-operator_assign-0cd]

= Function param::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/param.hpp#L224[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(const xref:boost-urls-param[param]&) = default;
----

== Description

pass:v,q[Upon assignment, this becomes a copy] pass:v,q[of `other`.]

=== Postconditions
[,cpp]
----
this->key == other.key && this->value == other.value && this->has_value == other.has_value
----

=== Complexity
pass:v,q[Linear in `other.key.size() + other.value.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]

=== other The object to assign from.



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| **
| ``

|===




[#boost-urls-param-operator_assign-0cb]

= Function param::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/param.hpp#L303[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(const xref:boost-urls-param_view[param_view]& other);
----

== Description

pass:v,q[The members of `other` are copied,] pass:v,q[re-using already existing string capacity.]

=== Postconditions
[,cpp]
----
this->key == other.key && this->value == other.value && this->has_value == other.has_value
----

=== Complexity
pass:v,q[Linear in `other.key.size() + other.value.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-param-operator_assign-03]

= Function param::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/param.hpp#L324[boost/url/param.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-param[param]&
operator=(const xref:boost-urls-param_pct_view[param_pct_view]& other);
----

== Description

pass:v,q[The members of `other` are copied,] pass:v,q[re-using already existing string capacity.]

=== Postconditions
[,cpp]
----
this->key == other.key && this->value == other.value && this->has_value == other.has_value
----

=== Complexity
pass:v,q[Linear in `other.key.size() + other.value.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-operator_lshift-04]

= Function operator<<

pass:v,q[Format the string with percent-decoding applied to the output stream]


== Synopsis

Declared in header `</boost/url/decode_view.hpp#L662[boost/url/decode_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-decode_view[decode_view]& s);
----

== Description

pass:v,q[This function serializes the decoded view] pass:v,q[to the output stream.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *s*
| ``

|===




[#boost-urls-operator_lshift-008]

= Function operator<<

pass:v,q[Format the address to an output stream.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L327[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-ipv4_address[ipv4_address]& addr);
----

== Description

pass:v,q[IPv4 addresses written to output streams] pass:v,q[are written in their dotted decimal format.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *addr*
| ``

|===




[#boost-urls-operator_lshift-001]

= Function operator<<

pass:v,q[Format the address to an output stream]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L368[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-ipv6_address[ipv6_address]& addr);
----

== Description

pass:v,q[This function writes the address to an] pass:v,q[output stream using standard notation.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *addr*
| ``

|===




[#boost-urls-operator_lshift-0e]

= Function operator<<

pass:v,q[Format the encoded authority to the output stream]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L1386[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-authority_view[authority_view]& a);
----

== Description

pass:v,q[This function serializes the encoded URL] pass:v,q[to the output stream.]

=== Example
[,cpp]
----
authority_view a( "www.example.com" );

std::cout << a << std::endl;
----



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *a*
| ``

|===




[#boost-urls-operator_lshift-01]

= Function operator<<

pass:v,q[Format to an output stream]


== Synopsis

Declared in header `</boost/url/segments_encoded_base.hpp#L326[boost/url/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-segments_encoded_base[segments_encoded_base]& ps);
----

== Description

pass:v,q[Any percent-escapes are emitted as-is;] pass:v,q[no decoding is performed.]

=== Complexity
pass:v,q[Linear in `ps.buffer().size()`.]

=== Effects
[,cpp]
----
return os << ps.buffer();
----



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *ps*
| ``

|===




[#boost-urls-operator_lshift-0b9]

= Function operator<<

pass:v,q[Format to an output stream]


== Synopsis

Declared in header `</boost/url/segments_base.hpp#L317[boost/url/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-segments_base[segments_base]& ps);
----

== Description

pass:v,q[Any percent-escapes are emitted as-is;] pass:v,q[no decoding is performed.]

=== Complexity
pass:v,q[Linear in `ps.buffer().size()`.]

=== Effects
[,cpp]
----
return os << ps.buffer();
----



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *ps*
| ``

|===




[#boost-urls-operator_lshift-0b8]

= Function operator<<

pass:v,q[Format to an output stream]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L539[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-params_encoded_base[params_encoded_base]& qp);
----

== Description

pass:v,q[Any percent-escapes are emitted as-is;] pass:v,q[no decoding is performed.]

=== Complexity
pass:v,q[Linear in `ps.buffer().size()`.]

=== Effects
[,cpp]
----
return os << ps.buffer();
----



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *qp*
| ``

|===




[#boost-urls-operator_lshift-0c]

= Function operator<<

pass:v,q[Format to an output stream]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L509[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-params_base[params_base]& qp);
----

== Description

pass:v,q[Any percent-escapes are emitted as-is;] pass:v,q[no decoding is performed.]

=== Complexity
pass:v,q[Linear in `ps.buffer().size()`.]

=== Effects
[,cpp]
----
return os << ps.buffer();
----



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *qp*
| ``

|===




[#boost-urls-operator_lshift-05]

= Function operator<<

pass:v,q[Format the url to the output stream]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2778[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ostream&
operator<<(
    ostream& os,
    const xref:boost-urls-url_view_base[url_view_base]& u);
----

== Description

pass:v,q[This function serializes the url to] pass:v,q[the specified output stream. Any]
pass:v,q[percent-escapes are emitted as-is;]
pass:v,q[no decoding is performed.]

=== Example
[,cpp]
----
url_view u( "http://www.example.com/index.htm" );
std::stringstream ss;
ss << u;
assert( ss.str() == "http://www.example.com/index.htm" );
----

=== Effects
[,cpp]
----
return os << u.buffer();
----

=== Complexity
pass:v,q[Linear in `u.buffer().size()`]

=== Exception Safety
pass:v,q[Basic guarantee.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *os*
| ``

| *u*
| ``

|===




[#boost-urls-ipv4_address-2constructor-0c]

= Function ipv4_address::ipv4_address

pass:v,q[Constructor.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L76[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv4_address() = default;
----


[#boost-urls-ipv4_address-2constructor-0d]

= Function ipv4_address::ipv4_address

pass:v,q[Constructor.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L80[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv4_address(const xref:boost-urls-ipv4_address[ipv4_address]&) = default;
----


[#boost-urls-ipv4_address-2constructor-06]

= Function ipv4_address::ipv4_address

pass:v,q[Construct from an unsigned integer.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L103[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv4_address(xref:boost-urls-ipv4_address-uint_type[uint_type] u) noexcept;
----

== Description

pass:v,q[This function constructs an address from] pass:v,q[the unsigned integer `u`, where the most]
pass:v,q[significant byte forms the first octet]
pass:v,q[of the resulting address.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *u*
| `uint_type`

|===




[#boost-urls-ipv4_address-2constructor-0f]

= Function ipv4_address::ipv4_address

pass:v,q[Construct from an array of bytes.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L116[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv4_address(const xref:boost-urls-ipv4_address-bytes_type[bytes_type]& bytes) noexcept;
----

== Description

pass:v,q[This function constructs an address] pass:v,q[from the array in `bytes`, which is]
pass:v,q[interpreted in big-endian.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *bytes*
| ``

|===




[#boost-urls-ipv4_address-2constructor-08]

= Function ipv4_address::ipv4_address

pass:v,q[Construct from a string.]


== Synopsis

Declared in header `</boost/url/ipv4_address.hpp#L146[boost/url/ipv4_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv4_address(string_view s);
----

== Description

pass:v,q[This function constructs an address from] pass:v,q[the string `s`, which must contain a valid]
pass:v,q[IPv4 address string or else an exception]
pass:v,q[is thrown.]
[NOTE]
pass:v,q[For a non-throwing parse function,]
pass:v,q[use]
xref:boost-urls-parse_ipv4_address[parse_ipv4_address.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-ipv6_address-2constructor-04]

= Function ipv6_address::ipv6_address

pass:v,q[Constructor.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L103[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv6_address() = default;
----

== Description

pass:v,q[Default constructed objects represent] pass:v,q[the unspecified address.]

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.5.2[2.5.2. The Unspecified Address]



== Return Value

* `void` 





[#boost-urls-ipv6_address-2constructor-06]

= Function ipv6_address::ipv6_address

pass:v,q[Constructor.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L107[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ipv6_address(const xref:boost-urls-ipv6_address[ipv6_address]&) = default;
----


[#boost-urls-ipv6_address-2constructor-0a]

= Function ipv6_address::ipv6_address

pass:v,q[Construct from an array of bytes.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L125[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv6_address(const xref:boost-urls-ipv6_address-bytes_type[bytes_type]& bytes) noexcept;
----

== Description

pass:v,q[This function constructs an address] pass:v,q[from the array in `bytes`, which is]
pass:v,q[interpreted in big-endian.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *bytes*
| ``

|===




[#boost-urls-ipv6_address-2constructor-08]

= Function ipv6_address::ipv6_address

pass:v,q[Construct from an IPv4 address.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L141[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv6_address(const xref:boost-urls-ipv4_address[ipv4_address]& addr) noexcept;
----

== Description

pass:v,q[This function constructs an IPv6 address] pass:v,q[from the IPv4 address `addr`. The resulting]
pass:v,q[address is an IPv4-Mapped IPv6 Address.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc4291#section-2.5.5.2[2.5.5.2. IPv4-Mapped IPv6 Address (rfc4291)]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *addr*
| ``

|===




[#boost-urls-ipv6_address-2constructor-00]

= Function ipv6_address::ipv6_address

pass:v,q[Construct from a string.]


== Synopsis

Declared in header `</boost/url/ipv6_address.hpp#L170[boost/url/ipv6_address.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
ipv6_address(string_view s);
----

== Description

pass:v,q[This function constructs an address from] pass:v,q[the string `s`, which must contain a valid]
pass:v,q[IPv6 address string or else an exception]
pass:v,q[is thrown.]
[NOTE]
pass:v,q[For a non-throwing parse function,]
pass:v,q[use]
xref:boost-urls-parse_ipv6_address[parse_ipv6_address.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2.2[3.2.2. Host (rfc3986)]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_view-operator_assign-02]

= Function url_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L283[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_view[url_view]&
operator=(const xref:boost-urls-url_view[url_view]& other) noexcept;
----

== Description

pass:v,q[After assignment, both views] pass:v,q[reference the same underlying character]
pass:v,q[buffer. Ownership is not transferred.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-url_view-operator_assign-0f]

= Function url_view::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L310[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url_view[url_view]&
operator=(const xref:boost-urls-url_view_base[url_view_base]& other) noexcept;
----

== Description

pass:v,q[After assignment, both views] pass:v,q[reference the same underlying character]
pass:v,q[buffer. Ownership is not transferred.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-url_view-2constructor-0c]

= Function url_view::url_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L146[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view() noexcept = default;
----

== Description

pass:v,q[Default constructed views refer to] pass:v,q[a string with zero length, which]
pass:v,q[always remains valid. This matches]
pass:v,q[the grammar for a relative-ref with]
pass:v,q[an empty path and no query or]
pass:v,q[fragment.]

=== Example
[,cpp]
----
url_view u;
----

=== Postconditions
[,cpp]
----
this->empty() == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification
link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.2[4.2. Relative Reference (rfc3986)]



== Return Value

* `void` 





[#boost-urls-url_view-2constructor-025]

= Function url_view::url_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L197[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view(string_view s);
----

== Description

pass:v,q[This function constructs a URL from] pass:v,q[the string `s`, which must contain a]
pass:v,q[valid]
pass:v,q[URI]
pass:v,q[or]
pass:v,q[relative-ref]
pass:v,q[or else an exception is thrown. Upon]
pass:v,q[successful construction, the view]
pass:v,q[refers to the characters in the]
pass:v,q[buffer pointed to by `s`.]
pass:v,q[Ownership is not transferred; The caller]
pass:v,q[is responsible for ensuring that the]
pass:v,q[lifetime of the buffer extends until]
pass:v,q[it is no longer referenced.]

=== Example
[,cpp]
----
url_view u( "http://www.example.com/index.htm" );
----

=== Effects
[,cpp]
----
return parse_uri_reference( s ).value();
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

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

relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.1[4.1. URI Reference]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_view-2constructor-00]

= Function url_view::url_view



== Synopsis

Declared in header `</boost/url/url_view.hpp#L215[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<
    class String,
    class = enable_if<std::is_convertible<String, core::string_view>::value && !std::is_convertible<String *, url_view_base *>::value>::type>
url_view(const String& s);
----


[#boost-urls-url_view-2constructor-024]

= Function url_view::url_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L239[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view(const xref:boost-urls-url_view[url_view]& other) noexcept;
----

== Description

pass:v,q[After construction, both views] pass:v,q[reference the same underlying character]
pass:v,q[buffer. Ownership is not transferred.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-url_view-2constructor-0a]

= Function url_view::url_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url_view.hpp#L263[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url_view(const xref:boost-urls-url_view_base[url_view_base]& other) noexcept;
----

== Description

pass:v,q[After construction, both views] pass:v,q[reference the same underlying character]
pass:v,q[buffer. Ownership is not transferred.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-authority_view-2constructor-0e]

= Function authority_view::authority_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L121[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
authority_view() noexcept;
----

== Description

pass:v,q[Default constructed authorities] pass:v,q[refer to a string with zero length,]
pass:v,q[which is always valid. This matches]
pass:v,q[the grammar for a zero-length host.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification



== Return Value

* `void` 





[#boost-urls-authority_view-2constructor-03]

= Function authority_view::authority_view

pass:v,q[Construct from a string.]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L158[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
authority_view(string_view s);
----

== Description

pass:v,q[This function attempts to construct] pass:v,q[an authority from the string `s`,]
pass:v,q[which must be a valid ['authority] or]
pass:v,q[else an exception is thrown. Upon]
pass:v,q[successful construction, the view]
pass:v,q[refers to the characters in the]
pass:v,q[buffer pointed to by `s`.]
pass:v,q[Ownership is not transferred; The]
pass:v,q[caller is responsible for ensuring]
pass:v,q[that the lifetime of the buffer]
pass:v,q[extends until the view is destroyed.]

=== BNF
[,cpp]
----
authority     = [ userinfo "@" ] host [ ":" port ]

userinfo      = user [ ":" [ password ] ]

user          = *( unreserved / pct-encoded / sub-delims )
password      = *( unreserved / pct-encoded / sub-delims / ":" )

host          = IP-literal / IPv4address / reg-name

port          = *DIGIT
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.2[3.2. Authority (rfc3986)]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-authority_view-2constructor-04]

= Function authority_view::authority_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/authority_view.hpp#L163[boost/url/authority_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
authority_view(const xref:boost-urls-authority_view[authority_view]&) noexcept = default;
----


[#boost-urls-ignore_case_param-2constructor-03]

= Function ignore_case_param::ignore_case_param

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/ignore_case.hpp#L71[boost/url/ignore_case.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ignore_case_param() noexcept = default;
----

== Description

pass:v,q[By default, comparisons are] pass:v,q[case-sensitive.]

=== Example
pass:v,q[This function performs case-sensitive]
pass:v,q[comparisons when called with no]
pass:v,q[arguments:]
[,cpp]
----
void f( ignore_case_param = {} );
----



== Return Value

* `void` 





[#boost-urls-ignore_case_param-2constructor-01]

= Function ignore_case_param::ignore_case_param

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/ignore_case.hpp#L88[boost/url/ignore_case.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
ignore_case_param(xref:boost-urls-ignore_case_t[ignore_case_t]) noexcept;
----

== Description

pass:v,q[Construction from] xref:boost-urls-ignore_case[ignore_case] pass:v,q[indicates that comparisons should]
pass:v,q[be case-insensitive.]

=== Example
pass:v,q[When]
xref:boost-urls-ignore_case[ignore_case]
pass:v,q[is passed as]
pass:v,q[an argument, this function ignores]
pass:v,q[case when performing comparisons:]
[,cpp]
----
void f( ignore_case_param = {} );
----



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| **
| `ignore_case_t`

|===




[#boost-urls-segments_encoded_base-iterator-2constructor-06]

= Function segments_encoded_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L47[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator() = default;
----


[#boost-urls-segments_encoded_base-iterator-2constructor-02]

= Function segments_encoded_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L48[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-segments_encoded_base-iterator[iterator]&) = default;
----


[#boost-urls-segments_encoded_base-iterator-operator_inc-08]

= Function segments_encoded_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L64[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]&
operator++() noexcept;
----


[#boost-urls-segments_encoded_base-iterator-operator_inc-0e]

= Function segments_encoded_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L78[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]
operator++(int) noexcept;
----


[#boost-urls-segments_encoded_base-iterator-operator_dec-00]

= Function segments_encoded_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L71[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]&
operator--() noexcept;
----


[#boost-urls-segments_encoded_base-iterator-operator_dec-05]

= Function segments_encoded_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/segments_encoded_base.hpp#L86[boost/url/impl/segments_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base-iterator[iterator]
operator--(int) noexcept;
----


[#boost-urls-segments_base-iterator-2constructor-0a]

= Function segments_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L46[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator() = default;
----


[#boost-urls-segments_base-iterator-2constructor-00]

= Function segments_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L47[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-segments_base-iterator[iterator]&) = default;
----


[#boost-urls-segments_base-iterator-operator_inc-08]

= Function segments_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L58[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]&
operator++() noexcept;
----


[#boost-urls-segments_base-iterator-operator_inc-07]

= Function segments_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L72[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]
operator++(int) noexcept;
----


[#boost-urls-segments_base-iterator-operator_dec-0f]

= Function segments_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L65[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]&
operator--() noexcept;
----


[#boost-urls-segments_base-iterator-operator_dec-0d]

= Function segments_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/segments_base.hpp#L80[boost/url/impl/segments_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base-iterator[iterator]
operator--(int) noexcept;
----


[#boost-urls-segments_view-2constructor-0c]

= Function segments_view::segments_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_view.hpp#L87[boost/url/segments_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_view() = default;
----

== Description

pass:v,q[Default-constructed segments have] pass:v,q[zero elements.]

=== Example
[,cpp]
----
segments_view ps;
----

=== Effects
[,cpp]
----
return segments_view( "" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-segments_view-2constructor-0d]

= Function segments_view::segments_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_view.hpp#L111[boost/url/segments_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_view(const xref:boost-urls-segments_view[segments_view]& other) = default;
----

== Description

pass:v,q[After construction, viewss] pass:v,q[reference the same underlying character]
pass:v,q[buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-segments_view-2constructor-0e]

= Function segments_view::segments_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_view.hpp#L163[boost/url/segments_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
segments_view(string_view s);
----

== Description

pass:v,q[This function constructs segments from] pass:v,q[a valid path string, which can contain]
pass:v,q[percent escapes.]
pass:v,q[Upon construction, the view references]
pass:v,q[the character buffer pointed to by `s`.]
pass:v,q[caller is responsible for ensuring]
pass:v,q[that the lifetime of the buffer]
pass:v,q[extends until the view is destroyed.]

=== Example
[,cpp]
----
segments_view ps( "/path/to/file.txt" );
----

=== Effects
[,cpp]
----
return parse_path( s ).value();
----

=== Postconditions
[,cpp]
----
this->buffer().data() == s.data()
----

=== Complexity
pass:v,q[Linear in `s`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
path = [ "/" ] [ segment *( "/" segment ) ]

segment = *pchar
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-segments_encoded_view-2constructor-0c]

= Function segments_encoded_view::segments_encoded_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_encoded_view.hpp#L92[boost/url/segments_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_encoded_view() = default;
----

== Description

pass:v,q[Default-constructed segments have] pass:v,q[zero elements.]

=== Example
[,cpp]
----
segments_encoded_view ps;
----

=== Effects
[,cpp]
----
return segments_encoded_view( "" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-segments_encoded_view-2constructor-0b]

= Function segments_encoded_view::segments_encoded_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_encoded_view.hpp#L115[boost/url/segments_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
segments_encoded_view(const xref:boost-urls-segments_encoded_view[segments_encoded_view]&) noexcept = default;
----

== Description

pass:v,q[After construction, both views] pass:v,q[reference the same character buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| **
| ``

|===




[#boost-urls-segments_encoded_view-2constructor-02]

= Function segments_encoded_view::segments_encoded_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/segments_encoded_view.hpp#L167[boost/url/segments_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
segments_encoded_view(string_view s);
----

== Description

pass:v,q[This function constructs segments from] pass:v,q[a valid path string, which can contain]
pass:v,q[percent escapes.]
pass:v,q[Upon construction, the view references]
pass:v,q[the character buffer pointed to by `s`.]
pass:v,q[caller is responsible for ensuring]
pass:v,q[that the lifetime of the buffer]
pass:v,q[extends until the view is destroyed.]

=== Example
[,cpp]
----
segments_encoded_view ps( "/path/to/file.txt" );
----

=== Effects
[,cpp]
----
return parse_path( s ).value();
----

=== Postconditions
[,cpp]
----
this->buffer().data() == s.data()
----

=== Complexity
pass:v,q[Linear in `s`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
path = [ "/" ] [ segment *( "/" segment ) ]

segment = *pchar
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-pct_encoded_rule-09]

= Function pct_encoded_rule



== Synopsis

Declared in header `</boost/url/rfc/pct_encoded_rule.hpp#L74[boost/url/rfc/pct_encoded_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet_>
constexpr
xref:boost-urls-pct_encoded_rule_t[pct_encoded_rule_t]<CharSet_>
pct_encoded_rule(const CharSet_& cs) noexcept;
----


[#boost-urls-pct_encoded_rule-08]

= Function pct_encoded_rule



== Synopsis

Declared in header `</boost/url/rfc/pct_encoded_rule.hpp#L98[boost/url/rfc/pct_encoded_rule.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class CharSet>
constexpr
xref:boost-urls-pct_encoded_rule_t[pct_encoded_rule_t]<CharSet>
pct_encoded_rule(const CharSet& cs) noexcept;
----


[#boost-urls-params_encoded_base-iterator-2constructor-0c]

= Function params_encoded_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L50[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator() = default;
----


[#boost-urls-params_encoded_base-iterator-2constructor-0e]

= Function params_encoded_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L51[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-params_encoded_base-iterator[iterator]&) = default;
----


[#boost-urls-params_encoded_base-iterator-operator_inc-09]

= Function params_encoded_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L55[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]&
operator++() noexcept;
----


[#boost-urls-params_encoded_base-iterator-operator_inc-03]

= Function params_encoded_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L62[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
operator++(int) noexcept;
----


[#boost-urls-params_encoded_base-iterator-operator_dec-01]

= Function params_encoded_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L70[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]&
operator--() noexcept;
----


[#boost-urls-params_encoded_base-iterator-operator_dec-05]

= Function params_encoded_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/params_encoded_base.hpp#L77[boost/url/impl/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
operator--(int) noexcept;
----


[#boost-urls-params_ref-2constructor-0b]

= Function params_ref::params_ref

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L120[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_ref(const xref:boost-urls-params_ref[params_ref]& other) = default;
----

== Description

pass:v,q[After construction, both views] pass:v,q[reference the same url. Ownership is not]
pass:v,q[transferred; the caller is responsible]
pass:v,q[for ensuring the lifetime of the url]
pass:v,q[extends until it is no longer]
pass:v,q[referenced.]

=== Postconditions
[,cpp]
----
&this->url() == &other.url()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-params_ref-2constructor-09]

= Function params_ref::params_ref

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L153[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
params_ref(
    const xref:boost-urls-params_ref[params_ref]& other,
    xref:boost-urls-encoding_opts[encoding_opts] opt) noexcept;
----

== Description

pass:v,q[After construction, both views will] pass:v,q[reference the same url but this]
pass:v,q[instance will use the specified]
xref:boost-urls-encoding_opts[encoding_opts]
pass:v,q[when the values]
pass:v,q[are decoded.]
pass:v,q[Ownership is not transferred; the]
pass:v,q[caller is responsible for ensuring]
pass:v,q[the lifetime of the url extends]
pass:v,q[until it is no longer referenced.]

=== Postconditions
[,cpp]
----
&this->url() == &other.url()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

| *opt*
| `encoding_opts`

|===




[#boost-urls-params_encoded_base-find-03]

= Function params_encoded_base::find

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L356[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find a match for]
pass:v,q[the specified key,]
pass:v,q[which may contain percent escapes.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts from the first param]
pass:v,q[and proceeds forward until either the]
pass:v,q[key is found or the end of the range is]
pass:v,q[reached, in which case `end()` is]
pass:v,q[returned.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).encoded_params().find( "First", ignore_case )->value == "John" );
----

=== Effects
[,cpp]
----
return this->find( this->begin(), key, ic );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_encoded_base-find-00]

= Function params_encoded_base::find

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L408[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find(
    xref:boost-urls-params_encoded_base-iterator[iterator] from,
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find a match for]
pass:v,q[the specified key, which may contain]
pass:v,q[percent escapes.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts at `from`]
pass:v,q[and proceeds forward until either the]
pass:v,q[key is found or the end of the range is]
pass:v,q[reached, in which case `end()` is]
pass:v,q[returned.]

=== Example
[,cpp]
----
url_view u( "?First=John&Last=Doe" );

assert( u.encoded_params().find( "first" ) != u.encoded_params().find( "first", ignore_case ) );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *key*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_encoded_base-find_last-05]

= Function params_encoded_base::find_last

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L456[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find_last(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find a match for]
pass:v,q[the specified key, which may contain]
pass:v,q[percent escapes.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts from the last param]
pass:v,q[and proceeds backwards until either the]
pass:v,q[key is found or the beginning of the]
pass:v,q[range is reached, in which case `end()`]
pass:v,q[is returned.]

=== Example
[,cpp]
----
assert( url_view( "?first=John&last=Doe" ).encoded_params().find_last( "last" )->value == "Doe" );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_encoded_base-find_last-0d]

= Function params_encoded_base::find_last

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_encoded_base.hpp#L503[boost/url/params_encoded_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base-iterator[iterator]
find_last(
    xref:boost-urls-params_encoded_base-iterator[iterator] before,
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find a match for]
pass:v,q[the specified key, which may contain]
pass:v,q[percent escapes.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts prior to `before`]
pass:v,q[and proceeds backwards until either the]
pass:v,q[key is found or the beginning of the]
pass:v,q[range is reached, in which case `end()`]
pass:v,q[is returned.]

=== Example
[,cpp]
----
url_view u( "?First=John&Last=Doe" );

assert( u.encoded_params().find_last( "last" ) != u.encoded_params().find_last( "last", ignore_case ) );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *key*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_ref-operator_assign-0c]

= Function params_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L184[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]&
operator=(const xref:boost-urls-params_ref[params_ref]& other);
----

== Description

pass:v,q[The previous contents of this are] pass:v,q[replaced by the contents of `other.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[The strings referenced by `other`]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Effects
[,cpp]
----
this->assign( other.begin(), other.end() );
----

=== Complexity
pass:v,q[Linear in `other.buffer().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-params_ref-operator_assign-03]

= Function params_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L214[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]&
operator=(initializer_list<xref:boost-urls-param_view[param_view]> init);
----

== Description

pass:v,q[After assignment, the previous contents] pass:v,q[of the query parameters are replaced by]
pass:v,q[the contents of the initializer-list.]

=== Preconditions
pass:v,q[None of character buffers referenced by]
pass:v,q[`init` may overlap the character buffer of]
pass:v,q[the underlying url, or else the behavior]
pass:v,q[is undefined.]

=== Effects
[,cpp]
----
this->assign( init );
----

=== Complexity
pass:v,q[Linear in `init.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-params_ref-assign-09]

= Function params_ref::assign

pass:v,q[Assign elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L315[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<xref:boost-urls-param_view[param_view]> init);
----

== Description

pass:v,q[This function replaces the entire] pass:v,q[contents of the view with the params]
pass:v,q[in the]
pass:v,q[initializer-list]
pass:v,q[.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Example
[,cpp]
----
url u;

u.params().assign( {{ "first", "John" }, { "last", "Doe" }} );
----

=== Complexity
pass:v,q[Linear in `init.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-params_ref-assign-02]

= Function params_ref::assign

pass:v,q[Assign elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L350[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function replaces the entire] pass:v,q[contents of the view with the params]
pass:v,q[in the range.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_view >::value == true
----

=== Complexity
pass:v,q[Linear in the size of the range.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-params_ref-append-0f]

= Function params_ref::append

pass:v,q[Append elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L380[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
append(const xref:boost-urls-param_view[param_view]& p);
----

== Description

pass:v,q[This function appends a param to the view.]
pass:v,q[The `end()` iterator is invalidated.]

=== Example
[,cpp]
----
url u;

u.params().append( { "first", "John" } );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *p*
| ``

|===




[#boost-urls-params_ref-append-07]

= Function params_ref::append

pass:v,q[Append elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L410[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
append(initializer_list<xref:boost-urls-param_view[param_view]> init);
----

== Description

pass:v,q[This function appends the params in] pass:v,q[an] pass:v,q[initializer-list]
pass:v,q[to the view.]
pass:v,q[The `end()` iterator is invalidated.]

=== Example
[,cpp]
----
url u;

u.params().append({ { "first", "John" }, { "last", "Doe" } });
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-params_ref-append-0c]

= Function params_ref::append

pass:v,q[Append elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L446[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
append(
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function appends a range of params] pass:v,q[to the view.]
pass:v,q[The `end()` iterator is invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_view >::value == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-params_ref-erase-05]

= Function params_ref::erase

pass:v,q[Erase elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L595[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
erase(xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] pos) noexcept;
----

== Description

pass:v,q[This function removes an element from] pass:v,q[the container.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

params_ref::iterator it = u.params().erase( u.params().begin() );

assert( u.encoded_query() == "last=Doe" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

|===




[#boost-urls-params_ref-erase-0f]

= Function params_ref::erase

pass:v,q[Erase elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L619[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
erase(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] first,
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] last) noexcept;
----

== Description

pass:v,q[This function removes a range of elements] pass:v,q[from the container.]
pass:v,q[All iterators that are equal to]
pass:v,q[`first` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *first*
| `iterator`

| *last*
| `iterator`

|===




[#boost-urls-params_ref-erase-00]

= Function params_ref::erase

pass:v,q[Erase elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L652[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
erase(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) noexcept;
----

== Description

pass:v,q[All iterators are invalidated.]

=== Postconditions
[,cpp]
----
this->count( key, ic ) == 0
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `size_t` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_ref-insert-08]

= Function params_ref::insert

pass:v,q[Insert elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L477[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
insert(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] before,
    const xref:boost-urls-param_view[param_view]& p);
----

== Description

pass:v,q[This function inserts a param] pass:v,q[before the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *p*
| ``

|===




[#boost-urls-params_ref-insert-02]

= Function params_ref::insert

pass:v,q[Insert elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L514[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
insert(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] before,
    initializer_list<xref:boost-urls-param_view[param_view]> init);
----

== Description

pass:v,q[This function inserts the params in] pass:v,q[an] pass:v,q[initializer-list]
pass:v,q[before]
pass:v,q[the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-params_ref-insert-05]

= Function params_ref::insert

pass:v,q[Insert elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L558[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
insert(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function inserts a range of] pass:v,q[params before the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_view >::value == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-params_ref-replace-0d]

= Function params_ref::replace

pass:v,q[Replace elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L691[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
replace(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] pos,
    const xref:boost-urls-param_view[param_view]& p);
----

== Description

pass:v,q[This function replaces the contents] pass:v,q[of the element at `pos` with the]
pass:v,q[specified param.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

u.params().replace( u.params().begin(), { "title", "Mr" });

assert( u.encoded_query() == "title=Mr&last=Doe" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

| *p*
| ``

|===




[#boost-urls-params_ref-replace-0b]

= Function params_ref::replace

pass:v,q[Replace elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L727[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
replace(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] from,
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] to,
    initializer_list<xref:boost-urls-param_view[param_view]> init);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[elements with the params in an]
pass:v,q[initializer-list]
pass:v,q[.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-params_ref-replace-01]

= Function params_ref::replace

pass:v,q[Replace elements]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L771[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
replace(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] from,
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[elements with a range of params.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_view >::value == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-params_ref-set-09]

= Function params_ref::set

pass:v,q[Set a value]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L848[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
set(
    xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator] pos,
    string_view value);
----

== Description

pass:v,q[This function replaces the value of an] pass:v,q[element at the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Example
[,cpp]
----
url u( "?id=42&id=69" );

u.params().set( u.params().begin(), "none" );

assert( u.encoded_query() == "id=none&id=69" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

| *value*
| `string_view`

|===




[#boost-urls-params_ref-set-01]

= Function params_ref::set

pass:v,q[Set a value]


== Synopsis

Declared in header `</boost/url/params_ref.hpp#L910[boost/url/params_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base[params_base]::xref:boost-urls-params_base-iterator[iterator]
set(
    string_view key,
    string_view value,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {});
----

== Description

pass:v,q[This function performs one of two] pass:v,q[actions depending on the value of]
pass:v,q[`this->contains( key, ic )`.]

* pass:v,q[If key is contained in the view]
pass:v,q[then one of the matching elements has]
pass:v,q[its value changed to the specified value.]
pass:v,q[The remaining elements with a matching]
pass:v,q[key are erased. Otherwise,]

* pass:v,q[If `key` is not contained in the]
pass:v,q[view, then the function apppends the]
pass:v,q[param `{ key, value }`.]
pass:v,q[All iterators are invalidated.]

=== Example
[,cpp]
----
url u( "?id=42&id=69" );

u.params().set( "id", "none" );

assert( u.params().count( "id" ) == 1 );
----

=== Postconditions
[,cpp]
----
this->count( key, ic ) == 1 && this->find( key, ic )->value == value
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *value*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_base-iterator-2constructor-0c]

= Function params_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L56[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
iterator() = default;
----


[#boost-urls-params_base-iterator-2constructor-00]

= Function params_base::iterator::iterator



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L57[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
iterator(const xref:boost-urls-params_base-iterator[iterator]&) = default;
----


[#boost-urls-params_base-iterator-operator_inc-01]

= Function params_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L61[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]&
operator++() noexcept;
----


[#boost-urls-params_base-iterator-operator_inc-09]

= Function params_base::iterator::operator++



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L68[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
operator++(int) noexcept;
----


[#boost-urls-params_base-iterator-operator_dec-0c]

= Function params_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L76[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]&
operator--() noexcept;
----


[#boost-urls-params_base-iterator-operator_dec-08]

= Function params_base::iterator::operator--



== Synopsis

Declared in header `</boost/url/impl/params_base.hpp#L83[boost/url/impl/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
operator--(int) noexcept;
----


[#boost-urls-params_base-find-09]

= Function params_base::find

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L341[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the parameters] pass:v,q[in the container to find a match for]
pass:v,q[the specified key.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts from the first param]
pass:v,q[and proceeds forward until either the]
pass:v,q[key is found or the end of the range is]
pass:v,q[reached, in which case `end()` is]
pass:v,q[returned.]

=== Example
[,cpp]
----
assert( (*url_view( "?first=John&last=Doe" ).params().find( "First", ignore_case )).value == "John" );
----

=== Effects
[,cpp]
----
return this->find( this->begin(), key, ic );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_base-find-04]

= Function params_base::find

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L386[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find(
    xref:boost-urls-params_base-iterator[iterator] from,
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the] pass:v,q[parameters in the container to] pass:v,q[find a match for the specified key.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts at `from`]
pass:v,q[and proceeds forward until either the]
pass:v,q[key is found or the end of the range is]
pass:v,q[reached, in which case `end()` is]
pass:v,q[returned.]

=== Example
[,cpp]
----
url_view u( "?First=John&Last=Doe" );

assert( u.params().find( "first" ) != u.params().find( "first", ignore_case ) );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *key*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_base-find_last-04]

= Function params_base::find_last

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L427[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find_last(
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the] pass:v,q[parameters in the container to] pass:v,q[find a match for the specified key.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts from the last param]
pass:v,q[and proceeds backwards until either the]
pass:v,q[key is found or the beginning of the]
pass:v,q[range is reached, in which case `end()`]
pass:v,q[is returned.]

=== Example
[,cpp]
----
assert( (*url_view( "?first=John&last=Doe" ).params().find_last( "last" )).value == "Doe" );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *key*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_base-find_last-0d]

= Function params_base::find_last

pass:v,q[Find a matching key]


== Synopsis

Declared in header `</boost/url/params_base.hpp#L473[boost/url/params_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_base-iterator[iterator]
find_last(
    xref:boost-urls-params_base-iterator[iterator] before,
    string_view key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) const noexcept;
----

== Description

pass:v,q[This function examines the] pass:v,q[parameters in the container to] pass:v,q[find a match for the specified key.]
pass:v,q[The comparison is performed as if all]
pass:v,q[escaped characters were decoded first.]
pass:v,q[The search starts prior to `before`]
pass:v,q[and proceeds backwards until either the]
pass:v,q[key is found or the beginning of the]
pass:v,q[range is reached, in which case `end()`]
pass:v,q[is returned.]

=== Example
[,cpp]
----
url_view u( "?First=John&Last=Doe" );

assert( u.params().find_last( "last" ) != u.params().find_last( "last", ignore_case ) );
----

=== Complexity
pass:v,q[Linear in `this->buffer().size()`.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *key*
| `string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_view-2constructor-0d]

= Function params_view::params_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_view.hpp#L80[boost/url/params_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view() = default;
----

== Description

pass:v,q[Default-constructed params have] pass:v,q[zero elements.]

=== Example
[,cpp]
----
params_view qp;
----

=== Effects
[,cpp]
----
return params_view( "" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-params_view-2constructor-091]

= Function params_view::params_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_view.hpp#L103[boost/url/params_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_view(const xref:boost-urls-params_view[params_view]& other) = default;
----

== Description

pass:v,q[After construction both views reference] pass:v,q[the same character buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-params_view-2constructor-01]

= Function params_view::params_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_view.hpp#L130[boost/url/params_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view(
    const xref:boost-urls-params_view[params_view]& other,
    xref:boost-urls-encoding_opts[encoding_opts] opt) noexcept;
----

== Description

pass:v,q[After construction both views will] pass:v,q[reference the same character buffer]
pass:v,q[but this instance will use the specified]
xref:boost-urls-encoding_opts[encoding_opts]
pass:v,q[when the values]
pass:v,q[are decoded.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

| *opt*
| `encoding_opts`

|===




[#boost-urls-params_view-2constructor-09a]

= Function params_view::params_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_view.hpp#L186[boost/url/params_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view(string_view s);
----

== Description

pass:v,q[This function constructs params from] pass:v,q[a valid query parameter string, which]
pass:v,q[can contain percent escapes. Unlike]
pass:v,q[the parameters in URLs, the string]
pass:v,q[passed here should not start with "?".]
pass:v,q[Upon construction, the view references]
pass:v,q[the character buffer pointed to by `s`.]
pass:v,q[The caller is responsible for ensuring]
pass:v,q[that the lifetime of the buffer extends]
pass:v,q[until it is no longer referenced.]

=== Example
[,cpp]
----
params_view qp( "first=John&last=Doe" );
----

=== Effects
[,cpp]
----
return parse_query( s ).value();
----

=== Postconditions
[,cpp]
----
this->buffer().data() == s.data()
----

=== Complexity
pass:v,q[Linear in `s`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query-params    = [ query-param ] *( "&" query-param )

query-param     = key [ "=" value ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-params_view-2constructor-04]

= Function params_view::params_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_view.hpp#L253[boost/url/params_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
params_view(
    string_view s,
    xref:boost-urls-encoding_opts[encoding_opts] opt);
----

== Description

pass:v,q[This function constructs params from] pass:v,q[a valid query parameter string, which]
pass:v,q[can contain percent escapes.]
pass:v,q[This instance will use the specified]
xref:boost-urls-encoding_opts[encoding_opts]
pass:v,q[when the values]
pass:v,q[are decoded.]
pass:v,q[Unlike the parameters in URLs, the string]
pass:v,q[passed here should not start with "?".]
pass:v,q[Upon construction, the view will]
pass:v,q[reference the character buffer pointed]
pass:v,q[to by `s`. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the]
pass:v,q[buffer extends until it is no longer]
pass:v,q[referenced.]

=== Example
[,cpp]
----
encoding_opts opt;
opt.space_as_plus = true;
params_view qp( "name=John+Doe", opt );
----

=== Effects
[,cpp]
----
return params_view(parse_query( s ).value(), opt);
----

=== Postconditions
[,cpp]
----
this->buffer().data() == s.data()
----

=== Complexity
pass:v,q[Linear in `s`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query-params    = [ query-param ] *( "&" query-param )

query-param     = key [ "=" value ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

| *opt*
| `encoding_opts`

|===




[#boost-urls-params_encoded_view-2constructor-02]

= Function params_encoded_view::params_encoded_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_encoded_view.hpp#L87[boost/url/params_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_encoded_view() = default;
----

== Description

pass:v,q[Default-constructed params have] pass:v,q[zero elements.]

=== Example
[,cpp]
----
params_encoded_view qp;
----

=== Effects
[,cpp]
----
return params_encoded_view( "" );
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 





[#boost-urls-params_encoded_view-2constructor-06]

= Function params_encoded_view::params_encoded_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_encoded_view.hpp#L110[boost/url/params_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
params_encoded_view(const xref:boost-urls-params_encoded_view[params_encoded_view]& other) = default;
----

== Description

pass:v,q[After construction both views] pass:v,q[reference the same character buffer.]
pass:v,q[Ownership is not transferred; the caller]
pass:v,q[is responsible for ensuring the lifetime]
pass:v,q[of the buffer extends until it is no]
pass:v,q[longer referenced.]

=== Postconditions
[,cpp]
----
this->buffer().data() == other.buffer().data()
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-params_encoded_view-2constructor-0c]

= Function params_encoded_view::params_encoded_view

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/params_encoded_view.hpp#L165[boost/url/params_encoded_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
params_encoded_view(string_view s);
----

== Description

pass:v,q[This function constructs params from] pass:v,q[a valid query parameter string, which]
pass:v,q[can contain percent escapes. Unlike]
pass:v,q[the parameters in URLs, the string]
pass:v,q[passed here should not start with "?".]
pass:v,q[Upon construction, the view]
pass:v,q[references the character buffer pointed]
pass:v,q[to by `s`. The caller is responsible]
pass:v,q[for ensuring that the lifetime of the]
pass:v,q[buffer extends until it is no longer]
pass:v,q[referenced.]

=== Example
[,cpp]
----
params_encoded_view qp( "first=John&last=Doe" );
----

=== Effects
[,cpp]
----
return parse_query( s ).value();
----

=== Postconditions
[,cpp]
----
this->buffer().data() == s.data()
----

=== Complexity
pass:v,q[Linear in `s`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

=== BNF
[,cpp]
----
query-params    = [ query-param ] *( "&" query-param )

query-param     = key [ "=" value ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url_base-segments-0e]

= Function url_base::segments

pass:v,q[Return the path as a container of segments]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1851[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]
segments() noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of segments over the path.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Any percent-escapes in strings returned]
pass:v,q[when iterating the view are decoded first.]
pass:v,q[The container is modifiable; changes]
pass:v,q[to the container are reflected in the]
pass:v,q[underlying URL.]

=== Example
[,cpp]
----
url u( "http://example.com/path/to/file.txt" );

segments sv = u.segments();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `segments_ref` 





[#boost-urls-url_base-segments-04]

= Function url_base::segments

pass:v,q[Return the path as a container of segments]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1855[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_view[segments_view]
segments() const noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of strings over the path.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Any percent-escapes in strings returned]
pass:v,q[when iterating the view are decoded first.]

=== Example
[,cpp]
----
segments_view sv = url_view( "/path/to/file.txt" ).segments();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = [ "/" ] segment *( "/" segment )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]



== Return Value

* `segments_view` 





[#boost-urls-url_base-encoded_segments-0e8]

= Function url_base::encoded_segments

pass:v,q[Return the path as a container of segments]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1912[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]
encoded_segments() noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of segments over the path.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Strings returned when iterating the]
pass:v,q[range may contain percent escapes.]
pass:v,q[The container is modifiable; changes]
pass:v,q[to the container are reflected in the]
pass:v,q[underlying URL.]

=== Example
[,cpp]
----
url u( "http://example.com/path/to/file.txt" );

segments_encoded_ref sv = u.encoded_segments();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3.  Path (rfc3986)]



== Return Value

* `segments_encoded_ref` 





[#boost-urls-url_base-encoded_segments-0e5]

= Function url_base::encoded_segments

pass:v,q[Return the path as a container of segments]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L1916[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_view[segments_encoded_view]
encoded_segments() const noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of strings over the path.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Strings returned when iterating the]
pass:v,q[range may contain percent escapes.]

=== Example
[,cpp]
----
segments_encoded_view sv = url_view( "/path/to/file.txt" ).encoded_segments();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
path          = path-abempty    ; begins with "/" or is empty
              / path-absolute   ; begins with "/" but not "//"
              / path-noscheme   ; begins with a non-colon segment
              / path-rootless   ; begins with a segment
              / path-empty      ; zero characters

path-abempty  = *( "/" segment )
path-absolute = "/" [ segment-nz *( "/" segment ) ]
path-noscheme = segment-nz-nc *( "/" segment )
path-rootless = segment-nz *( "/" segment )
path-empty    = 0<pchar>
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.3[3.3. Path (rfc3986)]



== Return Value

* `segments_encoded_view` 





[#boost-urls-url_base-params-03]

= Function url_base::params

pass:v,q[Return the query as a container of parameters]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2076[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]
params() noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of key/value pairs over the query.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Any percent-escapes in strings returned]
pass:v,q[when iterating the view are decoded first.]
pass:v,q[The container is modifiable; changes]
pass:v,q[to the container are reflected in the]
pass:v,q[underlying URL.]

=== Example
[,cpp]
----
params_ref pv = url( "/sql?id=42&name=jane%2Ddoe&page+size=20" ).params();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `params_ref` 





[#boost-urls-url_base-params-0b]

= Function url_base::params

xref:boost-urls-url_view_base-params-05[url_view_base::params]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2080[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_view[params_view]
params() const noexcept;
----


[#boost-urls-url_base-params-0c]

= Function url_base::params

pass:v,q[Return the query as a container of parameters]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2136[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_ref[params_ref]
params(xref:boost-urls-encoding_opts[encoding_opts] opt) noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of key/value pairs over the query.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Any percent-escapes in strings returned]
pass:v,q[when iterating the view are decoded first.]
pass:v,q[The container is modifiable; changes]
pass:v,q[to the container are reflected in the]
pass:v,q[underlying URL.]

=== Example
[,cpp]
----
encoding_opts opt;
opt.space_as_plus = true;
params_ref pv = url( "/sql?id=42&name=jane+doe&page+size=20" ).params(opt);
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `params_ref` 


== Parameters

|===
| Name | Type 

| *opt*
| `encoding_opts`

|===




[#boost-urls-url_base-encoded_params-02]

= Function url_base::encoded_params

pass:v,q[Return the query as a container of parameters]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2140[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_view[params_encoded_view]
encoded_params() const noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of key/value pairs over the query.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Strings returned when iterating the]
pass:v,q[range may contain percent escapes.]

=== Example
[,cpp]
----
params_encoded_view pv = url_view( "/sql?id=42&name=jane%2Ddoe&page+size=20" ).encoded_params();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `params_encoded_view` 





[#boost-urls-url_base-encoded_params-06]

= Function url_base::encoded_params

pass:v,q[Return the query as a container of parameters]


== Synopsis

Declared in header `</boost/url/url_base.hpp#L2190[boost/url/url_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_ref[params_encoded_ref]
encoded_params() noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of key/value pairs over the query.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Strings returned when iterating the]
pass:v,q[range may contain percent escapes.]
pass:v,q[The container is modifiable; changes]
pass:v,q[to the container are reflected in the]
pass:v,q[underlying URL.]

=== Example
[,cpp]
----
params_encoded_ref pv = url( "/sql?id=42&name=jane%2Ddoe&page+size=20" ).encoded_params();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4.  Query (rfc3986)]

* link:https://en.wikipedia.org/wiki/Query_string[Query string (Wikipedia)]



== Return Value

* `params_encoded_ref` 





[#boost-urls-params_encoded_ref-operator_assign-02]

= Function params_encoded_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L142[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_ref[params_encoded_ref]&
operator=(const xref:boost-urls-params_encoded_ref[params_encoded_ref]& other);
----

== Description

pass:v,q[The previous contents of this are] pass:v,q[replaced by the contents of `other.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[The strings referenced by `other`]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Effects
[,cpp]
----
this->assign( other.begin(), other.end() );
----

=== Complexity
pass:v,q[Linear in `other.buffer().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-params_encoded_ref-operator_assign-03]

= Function params_encoded_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L179[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_ref[params_encoded_ref]&
operator=(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
----

== Description

pass:v,q[After assignment, the previous contents] pass:v,q[of the query parameters are replaced by]
pass:v,q[the contents of the initializer-list.]
pass:v,q[All iterators are invalidated.]

=== Preconditions
pass:v,q[None of character buffers referenced by]
pass:v,q[`init` may overlap the character buffer of]
pass:v,q[the underlying url, or else the behavior]
pass:v,q[is undefined.]

=== Effects
[,cpp]
----
this->assign( init.begin(), init.end() );
----

=== Complexity
pass:v,q[Linear in `init.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-params_encoded_ref-assign-00]

= Function params_encoded_ref::assign

pass:v,q[Assign params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L289[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
----

== Description

pass:v,q[This function replaces the entire] pass:v,q[contents of the view with the params]
pass:v,q[in the]
pass:v,q[initializer-list]
pass:v,q[.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Example
[,cpp]
----
url u;

u.encoded_params().assign({ { "first", "John" }, { "last", "Doe" } });
----

=== Complexity
pass:v,q[Linear in `init.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-params_encoded_ref-assign-07]

= Function params_encoded_ref::assign

pass:v,q[Assign params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L328[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function replaces the entire] pass:v,q[contents of the view with the params]
pass:v,q[in the range.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_pct_view >::value == true
----

=== Complexity
pass:v,q[Linear in the size of the range.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-params_encoded_ref-append-07]

= Function params_encoded_ref::append

pass:v,q[Append params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L362[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
append(const xref:boost-urls-param_pct_view[param_pct_view]& p);
----

== Description

pass:v,q[This function appends a param to the view.]
pass:v,q[The `end()` iterator is invalidated.]

=== Example
[,cpp]
----
url u;

u.encoded_params().append( { "first", "John" } );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *p*
| ``

|===




[#boost-urls-params_encoded_ref-append-0e]

= Function params_encoded_ref::append

pass:v,q[Append params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L396[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
append(initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
----

== Description

pass:v,q[This function appends the params in] pass:v,q[an] pass:v,q[initializer-list]
pass:v,q[to the view.]
pass:v,q[The `end()` iterator is invalidated.]

=== Example
[,cpp]
----
url u;

u.encoded_params().append({ {"first", "John"}, {"last", "Doe"} });
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-params_encoded_ref-append-08]

= Function params_encoded_ref::append

pass:v,q[Append params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L436[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
append(
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function appends a range of params] pass:v,q[to the view.]
pass:v,q[The `end()` iterator is invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_pct_view >::value == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-params_encoded_ref-erase-08]

= Function params_encoded_ref::erase

pass:v,q[Erase params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L597[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
erase(xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] pos) noexcept;
----

== Description

pass:v,q[This function removes an element from] pass:v,q[the container.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

params_encoded_ref::iterator it = u.encoded_params().erase( u.encoded_params().begin() );

assert( u.encoded_query() == "last=Doe" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

|===




[#boost-urls-params_encoded_ref-erase-0b]

= Function params_encoded_ref::erase

pass:v,q[Erase params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L621[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
erase(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] first,
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] last) noexcept;
----

== Description

pass:v,q[This function removes a range of params] pass:v,q[from the container.]
pass:v,q[All iterators that are equal to]
pass:v,q[`first` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *first*
| `iterator`

| *last*
| `iterator`

|===




[#boost-urls-params_encoded_ref-erase-00]

= Function params_encoded_ref::erase

pass:v,q[Erase params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L657[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
size_t
erase(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {}) noexcept;
----

== Description

pass:v,q[All iterators are invalidated.]

=== Postconditions
[,cpp]
----
this->count( key, ic ) == 0
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `size_t` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_encoded_ref-insert-03]

= Function params_encoded_ref::insert

pass:v,q[Insert params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L471[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] before,
    const xref:boost-urls-param_pct_view[param_pct_view]& p);
----

== Description

pass:v,q[This function inserts a param] pass:v,q[before the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *p*
| ``

|===




[#boost-urls-params_encoded_ref-insert-0b]

= Function params_encoded_ref::insert

pass:v,q[Insert params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L512[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] before,
    initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
----

== Description

pass:v,q[This function inserts the params in] pass:v,q[an] pass:v,q[initializer-list]
pass:v,q[before]
pass:v,q[the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-params_encoded_ref-insert-05]

= Function params_encoded_ref::insert

pass:v,q[Insert params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L560[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function inserts a range of] pass:v,q[params before the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_pct_view >::value == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-params_encoded_ref-set-0d]

= Function params_encoded_ref::set

pass:v,q[Set a value]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L879[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
set(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] pos,
    xref:boost-urls-pct_string_view[pct_string_view] value);
----

== Description

pass:v,q[This function replaces the value of an] pass:v,q[element at the specified position.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]
[NOTE]
pass:v,q[The string passed in must not come]
pass:v,q[from the element being replaced,]
pass:v,q[or else the behavior is undefined.]

=== Example
[,cpp]
----
url u( "?id=42&id=69" );

u.encoded_params().set( u.encoded_params().begin(), "none" );

assert( u.encoded_query() == "id=none&id=69" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

| *value*
| `pct_string_view`

|===




[#boost-urls-params_encoded_ref-set-07]

= Function params_encoded_ref::set

pass:v,q[Set a value]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L951[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
set(
    xref:boost-urls-pct_string_view[pct_string_view] key,
    xref:boost-urls-pct_string_view[pct_string_view] value,
    xref:boost-urls-ignore_case_param[ignore_case_param] ic = = {});
----

== Description

pass:v,q[This function performs one of two] pass:v,q[actions depending on the value of]
pass:v,q[`this->contains( key, ic )`.]

* pass:v,q[If key is contained in the view]
pass:v,q[then one of the matching params has]
pass:v,q[its value changed to the specified value.]
pass:v,q[The remaining params with a matching]
pass:v,q[key are erased. Otherwise,]

* pass:v,q[If `key` is not contained in the]
pass:v,q[view, then the function apppends the]
pass:v,q[param `{ key, value }`.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[The strings passed in must not come]
pass:v,q[from the element being replaced,]
pass:v,q[or else the behavior is undefined.]

=== Example
[,cpp]
----
url u( "?id=42&id=69" );

u.encoded_params().set( "id", "none" );

assert( u.encoded_params().count( "id" ) == 1 );
----

=== Postconditions
[,cpp]
----
this->count( key, ic ) == 1 && this->find( key, ic )->value == value
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *key*
| `pct_string_view`

| *value*
| `pct_string_view`

| *ic*
| `ignore_case_param`

|===




[#boost-urls-params_encoded_ref-replace-0f]

= Function params_encoded_ref::replace

pass:v,q[Replace params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L705[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] pos,
    const xref:boost-urls-param_pct_view[param_pct_view]& p);
----

== Description

pass:v,q[This function replaces the contents] pass:v,q[of the element at `pos` with the]
pass:v,q[specified param.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]
[NOTE]
pass:v,q[The strings passed in must not come]
pass:v,q[from the element being replaced,]
pass:v,q[or else the behavior is undefined.]

=== Example
[,cpp]
----
url u( "?first=John&last=Doe" );

u.encoded_params().replace( u.encoded_params().begin(), { "title", "Mr" });

assert( u.encoded_query() == "title=Mr&last=Doe" );
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

| *p*
| ``

|===




[#boost-urls-params_encoded_ref-replace-08]

= Function params_encoded_ref::replace

pass:v,q[Replace params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L745[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] from,
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] to,
    initializer_list<xref:boost-urls-param_pct_view[param_pct_view]> init);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[params with the params in an]
pass:v,q[initializer-list]
pass:v,q[.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-params_encoded_ref-replace-06]

= Function params_encoded_ref::replace

pass:v,q[Replace params]


== Synopsis

Declared in header `</boost/url/params_encoded_ref.hpp#L793[boost/url/params_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] from,
    xref:boost-urls-params_encoded_base[params_encoded_base]::xref:boost-urls-params_encoded_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[params with a range of params.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]
[NOTE]
pass:v,q[The strings referenced by the inputs]
pass:v,q[must not come from the underlying url,]
pass:v,q[or else the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, param_pct_view >::value == true
----

=== Complexity
pass:v,q[Linear in `this->url().encoded_query().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-segments_encoded_ref-operator_assign-02c]

= Function segments_encoded_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L160[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]&
operator=(const xref:boost-urls-segments_encoded_ref[segments_encoded_ref]& other);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the other segments.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by `other` may overlap the buffer of the]
pass:v,q[underlying url, or else the behavior]
pass:v,q[is undefined.]

=== Effects
[,cpp]
----
this->assign( other.begin(), other.end() );
----

=== Complexity
pass:v,q[Linear in `other.buffer().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[@]
pass:v,q[{]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-segments_encoded_ref-operator_assign-02e]

= Function segments_encoded_ref::operator=



== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L164[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]&
operator=(const xref:boost-urls-segments_encoded_view[segments_encoded_view]& other);
----


[#boost-urls-segments_encoded_ref-operator_assign-08]

= Function segments_encoded_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L212[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_ref[segments_encoded_ref]&
operator=(initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the contents of the]
pass:v,q[initializer list.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the list are preserved.]
pass:v,q[All iterators are invalidated.]

=== Example
[,cpp]
----
url u;

u.encoded_segments() = {"path", "to", "file.txt"};
----

=== Preconditions
pass:v,q[None of the character buffers referenced]
pass:v,q[by the list may overlap the character buffer]
pass:v,q[of the underlying url, or else the behavior]
pass:v,q[is undefined.]

=== Effects
[,cpp]
----
this->assign( init.begin(), init.end() );
----

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-segments_encoded_ref-assign-0e]

= Function segments_encoded_ref::assign

pass:v,q[Assign segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L321[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the contents of the]
pass:v,q[initializer list.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the list are preserved.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by the list may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Example
[,cpp]
----
url u;

u.segments().assign( {"path", "to", "file.txt"} );
----

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-segments_encoded_ref-assign-0b]

= Function segments_encoded_ref::assign

pass:v,q[Assign segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L362[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the contents of the range.]
pass:v,q[Reserved characters in the range are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the range are preserved.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by the range may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, pct_string_view >::value == true
----

=== Complexity
pass:v,q[Linear in `std::distance( first, last ) + this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-segments_encoded_ref-erase-006]

= Function segments_encoded_ref::erase

pass:v,q[Erase segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L532[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
erase(xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] pos) noexcept;
----

== Description

pass:v,q[This function removes a segment.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

|===




[#boost-urls-segments_encoded_ref-erase-00a]

= Function segments_encoded_ref::erase

pass:v,q[Erase segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L558[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
erase(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] first,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] last) noexcept;
----

== Description

pass:v,q[This function removes a range of segments] pass:v,q[from the container.]
pass:v,q[All iterators that are equal to]
pass:v,q[`first` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *first*
| `iterator`

| *last*
| `iterator`

|===




[#boost-urls-segments_encoded_ref-insert-04]

= Function segments_encoded_ref::insert

pass:v,q[Insert segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L400[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] before,
    xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function inserts a segment] pass:v,q[before the specified position.]
pass:v,q[Reserved characters in the segment are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the segment are preserved.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `s.size() + this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *s*
| `pct_string_view`

|===




[#boost-urls-segments_encoded_ref-insert-0d]

= Function segments_encoded_ref::insert

pass:v,q[Insert segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L453[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] before,
    initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
----

== Description

pass:v,q[This function inserts the segments] pass:v,q[in an initializer list before the]
pass:v,q[specified position.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the list are preserved.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by the list may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Example
[,cpp]
----
url u( "/file.txt" );

u.encoded_segments().insert( u.encoded_segments().begin(), { "path", "to" } );
----

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-segments_encoded_ref-insert-07]

= Function segments_encoded_ref::insert

pass:v,q[Insert segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L505[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
insert(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function inserts the segments in] pass:v,q[a range before the specified position.]
pass:v,q[Reserved characters in the range are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the range are preserved.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by the range may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, pct_string_view >::value == true
----

=== Complexity
pass:v,q[Linear in `std::distance( first, last ) + this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-segments_ref-operator_assign-0d]

= Function segments_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L157[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]&
operator=(const xref:boost-urls-segments_ref[segments_ref]& other);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the other segments.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by `other` may overlap the buffer of the]
pass:v,q[underlying url, or else the behavior]
pass:v,q[is undefined.]

=== Effects
[,cpp]
----
this->assign( other.begin(), other.end() );
----

=== Complexity
pass:v,q[Linear in `other.buffer().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[@]
pass:v,q[{]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *other*
| ``

|===




[#boost-urls-segments_ref-operator_assign-08]

= Function segments_ref::operator=



== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L161[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]&
operator=(const xref:boost-urls-segments_view[segments_view]& other);
----


[#boost-urls-segments_ref-operator_assign-0f]

= Function segments_ref::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L204[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_ref[segments_ref]&
operator=(initializer_list<string_view> init);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the contents of the]
pass:v,q[initializer list.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators are invalidated.]

=== Example
[,cpp]
----
url u;

u.segments() = { "path", "to", "file.txt" };
----

=== Preconditions
pass:v,q[None of the character buffers referenced]
pass:v,q[by the list may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Effects
[,cpp]
----
this->assign( init.begin(), init.end() );
----

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-segments_encoded_ref-replace-07]

= Function segments_encoded_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L591[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] pos,
    xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function replaces the segment at] pass:v,q[the specified position.]
pass:v,q[Reserved characters in the string are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the string are preserved.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `s.size() + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

| *s*
| `pct_string_view`

|===




[#boost-urls-segments_encoded_ref-replace-06]

= Function segments_encoded_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L626[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] from,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] to,
    xref:boost-urls-pct_string_view[pct_string_view] s);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[segments with one segment.]
pass:v,q[Reserved characters in the string are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the string are preserved.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `s.size() + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *s*
| `pct_string_view`

|===




[#boost-urls-segments_encoded_ref-replace-08]

= Function segments_encoded_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L671[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] from,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] to,
    initializer_list<xref:boost-urls-pct_string_view[pct_string_view]> init);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[segments with a list of segments in]
pass:v,q[an initializer list.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the list are preserved.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]

=== Preconditions
pass:v,q[None of the character buffers referenced]
pass:v,q[by the list may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-segments_encoded_ref-replace-0f]

= Function segments_encoded_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_encoded_ref.hpp#L716[boost/url/segments_encoded_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator]
replace(
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] from,
    xref:boost-urls-segments_encoded_base[segments_encoded_base]::xref:boost-urls-segments_encoded_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[segments with annother range of segments.]
pass:v,q[Reserved characters in the new range are]
pass:v,q[automatically escaped.]
pass:v,q[Escapes in the new range are preserved.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]

=== Preconditions
pass:v,q[None of the character buffers referenced]
pass:v,q[by the new range may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `std::distance( first, last ) + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-segments_ref-assign-08]

= Function segments_ref::assign

pass:v,q[Assign segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L308[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
void
assign(initializer_list<string_view> init);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the contents of the]
pass:v,q[initializer list.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by `init` may overlap the character buffer]
pass:v,q[of the underlying url, or else the behavior]
pass:v,q[is undefined.]

=== Example
[,cpp]
----
url u;

u.segments().assign( { "path", "to", "file.txt" } );
----

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *init*
| `initializer_list`

|===




[#boost-urls-segments_ref-assign-0d]

= Function segments_ref::assign

pass:v,q[Assign segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L344[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
void
assign(
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[The existing contents are replaced] pass:v,q[by a copy of the contents of the range.]
pass:v,q[Reserved characters in the range are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by the range may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, core::string_view >::value == true
----

=== Complexity
pass:v,q[Linear in `std::distance( first, last ) + this->url().encoded_query().size() + this->url().encoded_fragment().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-segments_ref-erase-0af2]

= Function segments_ref::erase

pass:v,q[Erase segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L498[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
erase(xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] pos) noexcept;
----

== Description

pass:v,q[This function removes a segment.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

|===




[#boost-urls-segments_ref-erase-0af5]

= Function segments_ref::erase

pass:v,q[Erase segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L523[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
erase(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] first,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] last) noexcept;
----

== Description

pass:v,q[This function removes a range of segments.]
pass:v,q[All iterators that are equal to]
pass:v,q[`first` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *first*
| `iterator`

| *last*
| `iterator`

|===




[#boost-urls-segments_ref-insert-05]

= Function segments_ref::insert

pass:v,q[Insert segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L377[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
insert(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] before,
    string_view s);
----

== Description

pass:v,q[This function inserts a segment] pass:v,q[before the specified position.]
pass:v,q[Reserved characters in the segment are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `s.size() + this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *s*
| `string_view`

|===




[#boost-urls-segments_ref-insert-09]

= Function segments_ref::insert

pass:v,q[Insert segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L425[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
insert(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] before,
    initializer_list<string_view> init);
----

== Description

pass:v,q[This function inserts the segments] pass:v,q[in an initializer list before the]
pass:v,q[specified position.]
pass:v,q[Reserved characters in the list are]
pass:v,q[percent-escaped in the result.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by the list may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Example
[,cpp]
----
url u( "/file.txt" );

u.segments().insert( u.segments().begin(), { "path", "to" } );
----

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-segments_ref-insert-07]

= Function segments_ref::insert

pass:v,q[Insert segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L471[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
insert(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] before,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function inserts the segments in] pass:v,q[a range before the specified position.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators that are equal to]
pass:v,q[`before` or come after are invalidated.]
[NOTE]
pass:v,q[None of the character buffers referenced]
pass:v,q[by the range may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Mandates
[,cpp]
----
std::is_convertible< std::iterator_traits< FwdIt >::reference_type, core::string_view >::value == true
----

=== Complexity
pass:v,q[Linear in `std::distance( first, last ) + this->url().encoded_resource().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *before*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-segments_ref-replace-05]

= Function segments_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L555[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] pos,
    string_view s);
----

== Description

pass:v,q[This function replaces the segment at] pass:v,q[the specified position.]
pass:v,q[Reserved characters in the string are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators that are equal to]
pass:v,q[`pos` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `s.size() + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *pos*
| `iterator`

| *s*
| `string_view`

|===




[#boost-urls-segments_ref-replace-04]

= Function segments_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L585[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] from,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] to,
    string_view s);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[segments with one segment.]
pass:v,q[Reserved characters in the string are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]

=== Complexity
pass:v,q[Linear in `s.size() + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *s*
| `string_view`

|===




[#boost-urls-segments_ref-replace-02]

= Function segments_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L625[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] from,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] to,
    initializer_list<string_view> init);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[segments with a list of segments in]
pass:v,q[an initializer list.]
pass:v,q[Reserved characters in the list are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]

=== Preconditions
pass:v,q[None of the character buffers referenced]
pass:v,q[by the list may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `init.size() + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *init*
| `initializer_list`

|===




[#boost-urls-segments_ref-replace-07]

= Function segments_ref::replace

pass:v,q[Replace segments]


== Synopsis

Declared in header `</boost/url/segments_ref.hpp#L665[boost/url/segments_ref.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
template<class FwdIt>
xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator]
replace(
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] from,
    xref:boost-urls-segments_base[segments_base]::xref:boost-urls-segments_base-iterator[iterator] to,
    FwdIt first,
    FwdIt last);
----

== Description

pass:v,q[This function replaces a range of] pass:v,q[segments with annother range of segments.]
pass:v,q[Reserved characters in the new range are]
pass:v,q[automatically escaped.]
pass:v,q[All iterators that are equal to]
pass:v,q[`from` or come after are invalidated.]

=== Preconditions
pass:v,q[None of the character buffers referenced]
pass:v,q[by the new range may overlap the character]
pass:v,q[buffer of the underlying url, or else]
pass:v,q[the behavior is undefined.]

=== Complexity
pass:v,q[Linear in `std::distance( first, last ) + this->url().encoded_resouce().size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `iterator` 


== Parameters

|===
| Name | Type 

| *from*
| `iterator`

| *to*
| `iterator`

| *first*
| `FwdIt`

| *last*
| `FwdIt`

|===




[#boost-urls-url_view_base-params-06]

= Function url_view_base::params

pass:v,q[Return the query as a container of parameters]


== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L1997[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_view[params_view]
params() const noexcept;
----

== Description

pass:v,q[This function returns a bidirectional] pass:v,q[view of key/value pairs over the query.]
pass:v,q[The returned view references the same]
pass:v,q[underlying character buffer; ownership]
pass:v,q[is not transferred.]
pass:v,q[Any percent-escapes in strings returned]
pass:v,q[when iterating the view are decoded first.]

=== Example
[,cpp]
----
params_view pv = url_view( "/sql?id=42&name=jane%2Ddoe&page+size=20" ).params();
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
query           = *( pchar / "/" / "?" )

query-param     = key [ "=" value ]
query-params    = [ query-param ] *( "&" query-param )
----

=== Specification

* pass:v,q[://en.wikipedia.org/wiki/Query_string"]
pass:v,q[>Query string (Wikipedia)]



== Return Value

* `params_view` 





[#boost-urls-url_view_base-params-05]

= Function url_view_base::params



== Synopsis

Declared in header `</boost/url/url_view_base.hpp#L2000[boost/url/url_view_base.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-params_view[params_view]
params(xref:boost-urls-encoding_opts[encoding_opts] opt) const noexcept;
----


[#boost-urls-url-2constructor-0f0]

= Function url::url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url.hpp#L120[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url() noexcept = default;
----

== Description

pass:v,q[Default constructed urls contain] pass:v,q[a zero-length string. This matches]
pass:v,q[the grammar for a relative-ref with]
pass:v,q[an empty path and no query or]
pass:v,q[fragment.]

=== Example
[,cpp]
----
url u;
----

=== Postconditions
[,cpp]
----
this->empty() == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification
link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.2[4.2. Relative Reference (rfc3986)]



== Return Value

* `void` 





[#boost-urls-url-2constructor-002]

= Function url::url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url.hpp#L169[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url(string_view s);
----

== Description

pass:v,q[This function constructs a URL from] pass:v,q[the string `s`, which must contain a]
pass:v,q[valid]
pass:v,q[URI]
pass:v,q[or]
pass:v,q[relative-ref]
pass:v,q[or else an exception is thrown.]
pass:v,q[The new url retains ownership by]
pass:v,q[allocating a copy of the passed string.]

=== Example
[,cpp]
----
url u( "https://www.example.com" );
----

=== Effects
[,cpp]
----
return url( parse_uri_reference( s ).value() );
----

=== Postconditions
[,cpp]
----
this->buffer().data() != s.data()
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Calls to allocate may throw.]
pass:v,q[Exceptions thrown on invalid input.]

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

relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.1[4.1. URI Reference]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-url-2constructor-01]

= Function url::url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url.hpp#L194[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url(xref:boost-urls-url[url]&& u) noexcept;
----

== Description

pass:v,q[The contents of `u` are transferred] pass:v,q[to the newly constructed object,]
pass:v,q[which includes the underlying]
pass:v,q[character buffer.]
pass:v,q[After construction, the moved-from]
pass:v,q[object is as if default constructed.]

=== Postconditions
[,cpp]
----
u.empty() == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-url-2constructor-001]

= Function url::url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url.hpp#L217[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url(const xref:boost-urls-url_view_base[url_view_base]& u);
----

== Description

pass:v,q[The newly constructed object] pass:v,q[contains a copy of `u`.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer().data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-url-2constructor-0f7]

= Function url::url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/url.hpp#L243[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
url(const xref:boost-urls-url[url]& u);
----

== Description

pass:v,q[The newly constructed object] pass:v,q[contains a copy of `u`.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer().data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-url-operator_assign-09]

= Function url::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/url.hpp#L271[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
operator=(xref:boost-urls-url[url]&& u) noexcept;
----

== Description

pass:v,q[The contents of `u` are transferred to] pass:v,q[`this`, including the underlying]
pass:v,q[character buffer. The previous contents]
pass:v,q[of `this` are destroyed.]
pass:v,q[After assignment, the moved-from]
pass:v,q[object is as if default constructed.]

=== Postconditions
[,cpp]
----
u.empty() == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-url-operator_assign-0b]

= Function url::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/url.hpp#L297[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
operator=(const xref:boost-urls-url_view_base[url_view_base]& u);
----

== Description

pass:v,q[The contents of `u` are copied and] pass:v,q[the previous contents of `this` are]
pass:v,q[destroyed.]
pass:v,q[Capacity is preserved, or increases.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer().data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-url-operator_assign-06]

= Function url::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/url.hpp#L326[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-url[url]&
operator=(const xref:boost-urls-url[url]& u);
----

== Description

pass:v,q[The contents of `u` are copied and] pass:v,q[the previous contents of `this` are]
pass:v,q[destroyed.]
pass:v,q[Capacity is preserved, or increases.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer().data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Calls to allocate may throw.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-static_url-2constructor-098]

= Function static_url::static_url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L165[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url() noexcept;
----

== Description

pass:v,q[Default constructed urls contain] pass:v,q[a zero-length string. This matches]
pass:v,q[the grammar for a relative-ref with]
pass:v,q[an empty path and no query or]
pass:v,q[fragment.]

=== Example
[,cpp]
----
static_url< 1024 > u;
----

=== Postconditions
[,cpp]
----
this->empty() == true
----

=== Complexity
pass:v,q[Constant.]

=== Exception Safety
pass:v,q[Throws nothing.]

=== BNF
[,cpp]
----
relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification
link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.2[4.2. Relative Reference (rfc3986)]



== Return Value

* `void` 





[#boost-urls-static_url-2constructor-08]

= Function static_url::static_url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L217[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url(string_view s);
----

== Description

pass:v,q[This function constructs a url from] pass:v,q[the string `s`, which must contain a]
pass:v,q[valid]
pass:v,q[URI]
pass:v,q[or]
pass:v,q[relative-ref]
pass:v,q[or else an exception is thrown.]
pass:v,q[The new url retains ownership by]
pass:v,q[making a copy of the passed string.]

=== Example
[,cpp]
----
static_url< 1024 > u( "https://www.example.com" );
----

=== Effects
[,cpp]
----
return static_url( parse_uri_reference( s ).value() );
----

=== Postconditions
[,cpp]
----
this->buffer().data() != s.data()
----

=== Complexity
pass:v,q[Linear in `s.size()`.]

=== Exception Safety
pass:v,q[Exceptions thrown on invalid input.]

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

relative-ref  = relative-part [ "?" query ] [ "#" fragment ]
----

=== Specification

* link:https://datatracker.ietf.org/doc/html/rfc3986#section-4.1[4.1. URI Reference]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *s*
| `string_view`

|===




[#boost-urls-static_url-2constructor-09f]

= Function static_url::static_url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L243[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url(const xref:boost-urls-static_url[static_url]& u) noexcept;
----

== Description

pass:v,q[The newly constructed object contains] pass:v,q[a copy of `u`.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer.data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Exception thrown if maximum size exceeded.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-static_url-2constructor-0b]

= Function static_url::static_url

pass:v,q[Constructor]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L271[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
static_url(const xref:boost-urls-url_view_base[url_view_base]& u);
----

== Description

pass:v,q[The newly constructed object contains] pass:v,q[a copy of `u`.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer.data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Exception thrown if capacity exceeded.]



== Return Value

* `void` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-static_url-operator_assign-06]

= Function static_url::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L298[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
operator=(const xref:boost-urls-static_url[static_url]& u) noexcept;
----

== Description

pass:v,q[The contents of `u` are copied and] pass:v,q[the previous contents of `this` are]
pass:v,q[discarded.]
pass:v,q[Capacity remains unchanged.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer().data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Throws nothing.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#boost-urls-static_url-operator_assign-0c]

= Function static_url::operator=

pass:v,q[Assignment]


== Synopsis

Declared in header `</boost/url/static_url.hpp#L330[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
xref:boost-urls-static_url[static_url]&
operator=(const xref:boost-urls-url_view_base[url_view_base]& u);
----

== Description

pass:v,q[The contents of `u` are copied and] pass:v,q[the previous contents of `this` are]
pass:v,q[discarded.]

=== Postconditions
[,cpp]
----
this->buffer() == u.buffer() && this->buffer().data() != u.buffer().data()
----

=== Complexity
pass:v,q[Linear in `u.size()`.]

=== Exception Safety
pass:v,q[Strong guarantee.]
pass:v,q[Exception thrown if capacity exceeded.]



== Return Value

* `` 


== Parameters

|===
| Name | Type 

| *u*
| ``

|===




[#std-hash-04-2constructor-01]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/url.hpp#L525[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash() = default;
----


[#std-hash-04-2constructor-00]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/url.hpp#L526[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash(const xref:std-hash-04[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url[url]>&) = default;
----


[#std-hash-04-2constructor-06]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/url.hpp#L529[boost/url/url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(size_t salt) noexcept;
----


[#std-hash-0c-2constructor-07]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/url_view.hpp#L351[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash() = default;
----


[#std-hash-0c-2constructor-00]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/url_view.hpp#L352[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
constexpr
hash(const xref:std-hash-0c[hash]<xref:boost[boost]::xref:boost-urls[urls]::xref:boost-urls-url_view[url_view]>&) = default;
----


[#std-hash-0c-2constructor-05]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/url_view.hpp#L355[boost/url/url_view.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(size_t salt) noexcept;
----


[#std-hash-06-2constructor-0c]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/static_url.hpp#L449[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
hash() = default;
----


[#std-hash-06-2constructor-06]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/static_url.hpp#L450[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(const xref:std-hash-06[hash]&) = default;
----


[#std-hash-06-2constructor-0f]

= Function hash::hash



== Synopsis

Declared in header `</boost/url/static_url.hpp#L453[boost/url/static_url.hpp,window=blank_]>`

[source,cpp,subs="verbatim,macros,-callouts"]
----
hash(size_t salt) noexcept;
----


Created with MrDocs
