Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:53:28

0001 //
0002 // Copyright (c) 2016-2019 Vinnie Falco (vinnie dot falco at gmail dot com)
0003 //
0004 // Distributed under the Boost Software License, Version 1.0. (See accompanying
0005 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
0006 //
0007 // Official repository: https://github.com/boostorg/url
0008 //
0009 
0010 #ifndef BOOST_URL_RFC_ABSOLUTE_URI_RULE_HPP
0011 #define BOOST_URL_RFC_ABSOLUTE_URI_RULE_HPP
0012 
0013 #include <boost/url/detail/config.hpp>
0014 #include <boost/url/error_types.hpp>
0015 #include <boost/url/url_view.hpp>
0016 
0017 namespace boost {
0018 namespace urls {
0019 
0020 /** Rule for absolute-URI
0021 
0022     @par Value Type
0023     @code
0024     using value_type = url_view;
0025     @endcode
0026 
0027     @par Example
0028     Rules are used with the function @ref grammar::parse.
0029     @code
0030     system::result< url_view > rv = grammar::parse( "http://example.com/index.htm?id=1", absolute_uri_rule );
0031     @endcode
0032 
0033     @par BNF
0034     @code
0035     absolute-URI    = scheme ":" hier-part [ "?" query ]
0036 
0037     hier-part       = "//" authority path-abempty
0038                     / path-absolute
0039                     / path-rootless
0040                     / path-empty
0041     @endcode
0042 
0043     @par Specification
0044     @li <a href="https://datatracker.ietf.org/doc/html/rfc3986#section-4.3"
0045         >4.3. Absolute URI (rfc3986)</a>
0046 
0047     @see
0048         @ref grammar::parse,
0049         @ref parse_absolute_uri,
0050         @ref url_view.
0051 */
0052 #ifdef BOOST_URL_DOCS
0053 constexpr __implementation_defined__ absolute_uri_rule;
0054 #else
0055 struct absolute_uri_rule_t
0056 {
0057     using value_type = url_view;
0058 
0059     BOOST_URL_DECL
0060     auto
0061     parse(
0062         char const*& it,
0063         char const* end
0064             ) const noexcept ->
0065         system::result<value_type>;
0066 };
0067 
0068 constexpr absolute_uri_rule_t absolute_uri_rule{};
0069 #endif
0070 
0071 } // urls
0072 } // boost
0073 
0074 #endif