Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

grammar::literal_rule

Match a string literal exactly.

Synopsis

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

constexpr implementation-defined
literal_rule(
    char const* s);
Description

If there is no more input, or if the end of the input is reached, and a prefix of the literal matches exactly, the error returned will be error::need_more.

Value Type
using value_type = string_view;
Example

Rules are used with the function parse.

result< string_view > rv = parse( "HTTP", literal_rule( "HTTP" ) );
See Also

delim_rule, parse.

Convenience header <boost/url/grammar.hpp>


PrevUpHomeNext