Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the master branch, built from commit 9fc5439165.
PrevUpHomeNext
url::remove_fragment

Remove the fragment.

Synopsis
url_base&
remove_fragment();
Description

This function removes the fragment. An empty fragment is distinct from having no fragment.

Example
assert( url( "?first=john&last=doe#anchor" ).remove_fragment().buffer() == "?first=john&last=doe" );
Postconditions
this->has_fragment() == false && this->encoded_fragment() == ""
Complexity

Constant.

Exception Safety

Throws nothing.

BNF
fragment    = *( pchar / "/" / "?" )
Specification
See Also

remove_fragment, set_encoded_fragment, set_fragment.


PrevUpHomeNext