| 15817 | } |
| 15818 | |
| 15819 | tl::expected<std::string, errors> url_pattern_init::process_pathname( |
| 15820 | std::string_view value, std::string_view protocol, process_type type) { |
| 15821 | // If type is "pattern" then return pathnameValue. |
| 15822 | if (type == process_type::pattern) { |
| 15823 | return std::string(value); |
| 15824 | } |
| 15825 | |
| 15826 | // If protocolValue is a special scheme or the empty string, then return the |
| 15827 | // result of running canonicalize a pathname given pathnameValue. |
| 15828 | if (protocol.empty() || scheme::is_special(protocol)) { |
| 15829 | return url_pattern_helpers::canonicalize_pathname(value); |
| 15830 | } |
| 15831 | |
| 15832 | // Return the result of running canonicalize an opaque pathname given |
| 15833 | // pathnameValue. |
| 15834 | return url_pattern_helpers::canonicalize_opaque_pathname(value); |
| 15835 | } |
| 15836 | |
| 15837 | tl::expected<std::string, errors> url_pattern_init::process_search( |
| 15838 | std::string_view value, process_type type) { |
nothing calls this directly
no test coverage detected