MCPcopy Create free account
hub / github.com/dobin/RedEdr / dispatch_request

Method dispatch_request

RedEdr/httplib.h:6685–6697  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6683}
6684
6685inline bool Server::dispatch_request(Request &req, Response &res,
6686 const Handlers &handlers) const {
6687 for (const auto &x : handlers) {
6688 const auto &matcher = x.first;
6689 const auto &handler = x.second;
6690
6691 if (matcher->match(req)) {
6692 handler(req, res);
6693 return true;
6694 }
6695 }
6696 return false;
6697}
6698
6699inline void Server::apply_ranges(const Request &req, Response &res,
6700 std::string &content_type,

Callers

nothing calls this directly

Calls 1

matchMethod · 0.80

Tested by

no test coverage detected