#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "components/url_pattern/url_pattern_util.h"
#include <string_view>
#include "base/numerics/safe_conversions.h"
#include "base/ranges/ranges.h"
#include "base/strings/strcat.h"
#include "base/strings/string_util.h"
#include "url/url_util.h"
namespace url_pattern {
namespace {
std::string StdStringFromCanonOutput(const url::CanonOutput& output,
const url::Component& component) { … }
bool ContainsForbiddenHostnameCodePoint(std::string_view input) { … }
}
absl::StatusOr<std::string> ProtocolEncodeCallback(std::string_view input) { … }
absl::StatusOr<std::string> UsernameEncodeCallback(std::string_view input) { … }
absl::StatusOr<std::string> PasswordEncodeCallback(std::string_view input) { … }
absl::StatusOr<std::string> IPv6HostnameEncodeCallback(std::string_view input) { … }
absl::StatusOr<std::string> HostnameEncodeCallback(std::string_view input) { … }
absl::StatusOr<std::string> PortEncodeCallback(std::string_view input) { … }
absl::StatusOr<std::string> StandardURLPathnameEncodeCallback(
std::string_view input) { … }
absl::StatusOr<std::string> PathURLPathnameEncodeCallback(
std::string_view input) { … }
absl::StatusOr<std::string> SearchEncodeCallback(std::string_view input) { … }
absl::StatusOr<std::string> HashEncodeCallback(std::string_view input) { … }
bool TreatAsIPv6Hostname(std::string_view pattern_utf8) { … }
}