#include <orbit/legacy_namespaces.hpp>
#include <string>
#include <string_view>
#include <unordered_map>
#include <cstddef>
#include <cstdint>
#include <ctime>
#include <orbit/http/json.hpp>
#include <orbit/utils/CaseInsensitive.hpp>
Go to the source code of this file.
|
| enum class | orbit::http::HttpStatus {
orbit::http::Continue = 100
, orbit::http::SwitchingProtocols = 101
, orbit::http::OK = 200
, orbit::http::Created = 201
,
orbit::http::Accepted = 202
, orbit::http::NoContent = 204
, orbit::http::PartialContent = 206
, orbit::http::MovedPermanently = 301
,
orbit::http::Found = 302
, orbit::http::SeeOther = 303
, orbit::http::NotModified = 304
, orbit::http::TemporaryRedirect = 307
,
orbit::http::PermanentRedirect = 308
, orbit::http::BadRequest = 400
, orbit::http::Unauthorized = 401
, orbit::http::Forbidden = 403
,
orbit::http::NotFound = 404
, orbit::http::MethodNotAllowed = 405
, orbit::http::NotAcceptable = 406
, orbit::http::RequestTimeout = 408
,
orbit::http::Conflict = 409
, orbit::http::Gone = 410
, orbit::http::LengthRequired = 411
, orbit::http::PreconditionFailed = 412
,
orbit::http::PayloadTooLarge = 413
, orbit::http::URITooLong = 414
, orbit::http::UnsupportedMediaType = 415
, orbit::http::RangeNotSatisfiable = 416
,
orbit::http::ExpectationFailed = 417
, orbit::http::UnprocessableEntity = 422
, orbit::http::UpgradeRequired = 426
, orbit::http::TooManyRequests = 429
,
orbit::http::RequestHeaderFieldsTooLarge = 431
, orbit::http::InternalServerError = 500
, orbit::http::NotImplemented = 501
, orbit::http::BadGateway = 502
,
orbit::http::ServiceUnavailable = 503
, orbit::http::GatewayTimeout = 504
} |
| | Standard HTTP status codes. More...
|
| |
|
| const char * | orbit::http::reason_phrase (int status_code) |
| | Reason phrase for a status code. Codes without a registered phrase get a generic one for their class (e.g. "Client Error" for 4xx).
|
| |
| bool | orbit::http::is_valid_header_name (std::string_view name) |
| | True if name is a valid header field name (an RFC 9110 token).
|
| |
| bool | orbit::http::is_valid_header_value (std::string_view value) |
| | True if value can be written as a header field value: it contains no CR, LF or NUL, so it cannot start a new header line.
|
| |
| std::string | orbit::http::format_http_date (std::time_t t) |
| | Formats t as an IMF-fixdate (RFC 9110 section 5.6.7), e.g. "Sun, 06 Nov 1994 08:49:37 GMT", independent of the C locale.
|
| |
| std::string_view | orbit::http::http_date_now () |
| | The current time as an IMF-fixdate, for the Date header.
|
| |