HTTPMethod
Represents the HTTP methods supported by the server as a bitmask.
A lightweight wrapper for a short bitmap to handle HTTP method validations securely.
short getBitmap() const
Returns the raw bitmap.
bool isAllowed(HTTPMethod method) const
Checks if a specific HTTP method is permitted using bitwise AND.
void clear()
Clears all methods (resets to 0 / UNKNOWN_METHOD).
static std::string methodToString(HTTPMethod method)
static HTTPMethod stringToMethod(const std::string &methodStr)
Converts a string representation of an HTTP method to its enum value.
void addMethod(HTTPMethod method)
Adds an HTTP method to the allowed bitmap using bitwise OR.
void removeMethod(HTTPMethod method)
Removes an HTTP method from the allowed bitmap using bitwise AND NOT.
AllowedMethods & operator=(const AllowedMethods &other)