encoded_fragment
Return the fragment
Synopsis
pct_string_view
encoded_fragment() const noexcept;
Declared in file <include/boost/url/url_view_base.hpp> on line 2194
Defined in file <src/url_view_base.cpp> on line 578
Description
This function returns the fragment as a string with percent-escapes. Ownership is not transferred; the string returned references the underlying character buffer, which must remain valid or else undefined behavior occurs.
Example
assert( url_view( "http://www.example.com/index.htm#a%2D1" ).encoded_fragment() == "a%2D1" );