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 5002c2d6a2.
PrevUpHomeNext

string_token::arg

Base class for string tokens, and algorithm parameters.

Synopsis

Defined in header <boost/url/grammar/string_token.hpp>

struct arg
Member Functions

Name

Description

arg [constructor]

operator=

prepare

Return a modifiable character buffer.

Description

This abstract interface provides a means for an algorithm to generically obtain a modifiable, contiguous character buffer of prescribed size. As the author of an algorithm simply declare an rvalue reference as a parameter type.

Instances of this type are intended only to be used once and then destroyed.

Example

The declared function will accept any temporary instance of arg to be used for writing:

void algorithm( string_token::arg&& dest );

To implement the interface for your type or use-case, derive from the class and implement the prepare function.

Convenience header <boost/url/grammar.hpp>


PrevUpHomeNext