| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | // | ||
| 2 | // Copyright (c) 2019 Vinnie Falco (vinnie.falco@gmail.com) | ||
| 3 | // Copyright (c) 2022 Alan de Freitas (alandefreitas@gmail.com) | ||
| 4 | // | ||
| 5 | // Distributed under the Boost Software License, Version 1.0. (See accompanying | ||
| 6 | // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) | ||
| 7 | // | ||
| 8 | // Official repository: https://github.com/boostorg/url | ||
| 9 | // | ||
| 10 | |||
| 11 | |||
| 12 | #include <boost/url/detail/config.hpp> | ||
| 13 | #include <boost/url/detail/segments_range.hpp> | ||
| 14 | #include <boost/url/segments_view.hpp> | ||
| 15 | #include <boost/url/parse_path.hpp> | ||
| 16 | |||
| 17 | namespace boost { | ||
| 18 | namespace urls { | ||
| 19 | |||
| 20 | 103 | segments_view:: | |
| 21 | segments_view( | ||
| 22 | 103 | detail::path_ref const& ref) noexcept | |
| 23 | 103 | : segments_base(ref) | |
| 24 | { | ||
| 25 | 103 | } | |
| 26 | |||
| 27 | 19 | segments_view:: | |
| 28 | segments_view( | ||
| 29 | 19 | core::string_view s) | |
| 30 | : segments_base( | ||
| 31 |
2/2✓ Branch 3 taken 13 times.
✓ Branch 4 taken 6 times.
|
25 | parse_path(s).value( |
| 32 | 19 | BOOST_URL_POS)) | |
| 33 | { | ||
| 34 | 13 | } | |
| 35 | |||
| 36 | 20 | segments_view:: | |
| 37 | 20 | segments_view(iterator first, iterator last) noexcept | |
| 38 | 20 | : segments_base(detail::make_subref(first, last)) | |
| 39 | { | ||
| 40 | 20 | } | |
| 41 | |||
| 42 | } // urls | ||
| 43 | } // boost | ||
| 44 | |||
| 45 |