38enum class HttpMethod : uint8_t { kGet, kPost, kPut, kDelete, kHead };
43 case HttpMethod::kGet:
45 case HttpMethod::kPost:
47 case HttpMethod::kPut:
49 case HttpMethod::kDelete:
51 case HttpMethod::kHead:
62 using is_transparent = void;
64 bool operator()(std::string_view lhs, std::string_view rhs)
const noexcept {
65 const auto min_size = lhs.size() < rhs.size() ? lhs.size() : rhs.size();
66 for (std::size_t i = 0; i < min_size; ++i) {
67 auto left =
static_cast<unsigned char>(lhs[i]);
68 auto right =
static_cast<unsigned char>(rhs[i]);
69 const int lower_left = std::tolower(left);
70 const int lower_right = std::tolower(right);
71 if (lower_left < lower_right)
return true;
72 if (lower_left > lower_right)
return false;
74 return lhs.size() < rhs.size();
85using HttpHeaders = std::map<std::string, std::string, CaseInsensitiveHeaderLess>;
Define symbol visibility macros for the REST catalog library.
REST catalog APIs.
Definition auth_manager.h:34
std::map< std::string, std::string, CaseInsensitiveHeaderLess > HttpHeaders
Single-value HTTP headers with case-insensitive names.
Definition http_request.h:85
constexpr std::string_view ToString(HttpMethod method)
Convert HttpMethod to string representation.
Definition http_request.h:41
HttpMethod
HTTP method enumeration.
Definition http_request.h:38
An outgoing HTTP request. Mirrors Java's HttpRequest so signing implementations like SigV4 see method...
Definition http_request.h:89