File indexing completed on 2025-01-18 09:53:27
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef BOOST_URL_DETAIL_FORMAT_HPP
0011 #define BOOST_URL_DETAIL_FORMAT_HPP
0012
0013 #include <boost/url/detail/format_args.hpp>
0014 #include <boost/url/detail/pattern.hpp>
0015 #include <boost/core/detail/string_view.hpp>
0016 #include <boost/url/url.hpp>
0017
0018 namespace boost {
0019 namespace urls {
0020 namespace detail {
0021
0022 inline
0023 void
0024 vformat_to(
0025 url_base& u,
0026 core::string_view fmt,
0027 detail::format_args args)
0028 {
0029 parse_pattern(fmt)
0030 .value().apply(u, args);
0031 }
0032
0033 inline
0034 url
0035 vformat(
0036 core::string_view fmt,
0037 detail::format_args args)
0038 {
0039 url u;
0040 vformat_to(u, fmt, args);
0041 return u;
0042 }
0043
0044 }
0045 }
0046 }
0047
0048 #endif