Return the buffer size needed for percent-encoding
<boost/url/encode.hpp>
template<grammar::CharSet CS>
std::size_t
encoded_size(
    core::string_view s,
    CS const& allowed,
    encoding_opts opt = {}) noexcept;
This function returns the exact number of bytes necessary to store the result of applying percent-encoding to the string using the given options and character set. No encoding is actually performed.
assert( encoded_size( "My Stuff", pchars ) == 10 );
Throws nothing.
| Name | Description | 
|---|---|
| s | The string to measure. | 
| allowed | The set of characters that is not percent-encoded. | 
| opt | The options for encoding. If this parameter is omitted, the default options are be used. |