[#boost-urls-query_rule] = xref:boost.adoc[boost]::xref:boost/urls.adoc[urls]::query_rule :relfileprefix: ../../ :mrdocs: Rule for query == Synopsis Declared in `<https://www.github.com/boostorg/url/blob/develop/include/boost/url/rfc/query_rule.hpp#L110[boost/url/rfc/query_rule.hpp]>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- constexpr /* implementation-defined */::xref:boost/urls/implementation_defined/query_rule_t.adoc[query_rule_t] query_rule = {}; ---- == Description === Value Type [,cpp] ---- using value_type = params_encoded_view; ---- === Example Rules are used with the function xref:boost/urls/grammar/parse-02.adoc[grammar::parse]. [,cpp] ---- system::result< params_encoded_view > rv = grammar::parse( "format=web&id=42&compact", query_rule ); ---- === BNF [,cpp] ---- query = *( pchar / "/" / "?" ) query-params = [ query-param ] *( "&" query-param ) query-param = key [ "=" value ] key = *qpchar value = *( qpchar / "=" ) qpchar = unreserved / pct-encoded / "!" / "$" / "'" / "(" / ")" / "*" / "+" / "," / ";" / ":" / "@" / "/" / "?" ---- === Specification * link:https://datatracker.ietf.org/doc/html/rfc3986#section-3.4[3.4. Query (rfc3986)] == See Also xref:boost/urls/grammar/parse-02.adoc[grammar::parse], xref:boost/urls/params_encoded_view.adoc[params_encoded_view]. [.small]#Created with https://www.mrdocs.com[MrDocs]#