Thoth
A functional, expressive, asynchronous C++26 webdev library
Loading...
Searching...
No Matches
StatusCodeEnum.hpp File Reference
#include <expected>
#include <optional>
Include dependency graph for StatusCodeEnum.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  Thoth
 
namespace  Thoth::Http
 

Typedefs

template<class T >
using Thoth::Http::WebResult = std::expected< T, StatusCodeEnum >
 
using Thoth::Http::WebResultOper = WebResult< std::monostate >
 

Enumerations

enum class  Thoth::Http::StatusCodeEnum {
  Thoth::Http::CONTINUE = 100 , Thoth::Http::SWITCHING_PROTOCOLS = 101 , Thoth::Http::PROCESSING_DEPRECATED = 102 , Thoth::Http::EARLY_HINTS = 103 ,
  Thoth::Http::OK = 200 , Thoth::Http::CREATED = 201 , Thoth::Http::ACCEPTED = 202 , Thoth::Http::NON_AUTHORITATIVE_INFORMATION = 203 ,
  Thoth::Http::NO_CONTENT = 204 , Thoth::Http::RESET_CONTENT = 205 , Thoth::Http::PARTIAL_CONTENT = 206 , Thoth::Http::MULTI_STATUS = 207 ,
  Thoth::Http::ALREADY_REPORTED = 208 , Thoth::Http::IM_USED = 226 , Thoth::Http::MULTIPLE_CHOICES = 300 , Thoth::Http::MOVED_PERMANENTLY = 301 ,
  Thoth::Http::FOUND = 302 , Thoth::Http::SEE_OTHER = 303 , Thoth::Http::NOT_MODIFIED = 304 , Thoth::Http::USE_PROXY_DEPRECATED = 305 ,
  Thoth::Http::UNUSED = 306 , Thoth::Http::TEMPORARY_REDIRECT = 307 , Thoth::Http::PERMANENT_REDIRECT = 308 , Thoth::Http::BAD_REQUEST = 400 ,
  Thoth::Http::UNAUTHORIZED = 401 , Thoth::Http::PAYMENT_REQUIRED = 402 , Thoth::Http::FORBIDDEN = 403 , Thoth::Http::NOT_FOUND = 404 ,
  Thoth::Http::METHOD_NOT_ALLOWED = 405 , Thoth::Http::NOT_ACCEPTABLE = 406 , Thoth::Http::PROXY_AUTHENTICATION_REQUIRED = 407 , Thoth::Http::REQUEST_TIMEOUT = 408 ,
  Thoth::Http::CONFLICT = 409 , Thoth::Http::GONE = 410 , Thoth::Http::LENGTH_REQUIRED = 411 , Thoth::Http::PRECONDITION_FAILED = 412 ,
  Thoth::Http::CONTENT_TOO_LARGE = 413 , Thoth::Http::URI_TOO_LONG = 414 , Thoth::Http::UNSUPPORTED_MEDIA_TYPE = 415 , Thoth::Http::RANGE_NOT_SATISFIABLE = 416 ,
  Thoth::Http::EXPECTATION_FAILED = 417 , Thoth::Http::IM_A_TEAPOT = 418 , Thoth::Http::MISDIRECTED_REQUEST = 421 , Thoth::Http::UNPROCESSABLE_CONTENT = 422 ,
  Thoth::Http::LOCKED = 423 , Thoth::Http::FAILED_DEPENDENCY = 424 , Thoth::Http::TOO_EARLY_EXPERIMENTAL = 425 , Thoth::Http::UPGRADE_REQUIRED = 426 ,
  Thoth::Http::PRECONDITION_REQUIRED = 428 , Thoth::Http::TOO_MANY_REQUESTS = 429 , Thoth::Http::REQUEST_HEADER_FIELDS_TOO_LARGE = 431 , Thoth::Http::UNAVAILABLE_FOR_LEGAL_REASONS = 451 ,
  Thoth::Http::INTERNAL_SERVER_ERROR = 500 , Thoth::Http::NOT_IMPLEMENTED = 501 , Thoth::Http::BAD_GATEWAY = 502 , Thoth::Http::SERVICE_UNAVAILABLE = 503 ,
  Thoth::Http::GATEWAY_TIMEOUT = 504 , Thoth::Http::HTTP_VERSION_NOT_SUPPORTED = 505 , Thoth::Http::VARIANT_ALSO_NEGOTIATES = 506 , Thoth::Http::INSUFFICIENT_STORAGE = 507 ,
  Thoth::Http::LOOP_DETECTED = 508 , Thoth::Http::NOT_EXTENDED = 510 , Thoth::Http::NETWORK_AUTHENTICATION_REQUIRED = 511
}
 
enum class  Thoth::Http::StatusTypeEnum {
  Thoth::Http::INFORMATIONAL , Thoth::Http::SUCCESSFUL , Thoth::Http::REDIRECTION , Thoth::Http::CLIENT_ERROR ,
  Thoth::Http::SERVER_ERROR
}
 

Functions

constexpr StatusTypeEnum Thoth::Http::GetStatusType (StatusCodeEnum code)
 Check what type of code StatusCodeEnum is, the first digit of it's number.