MCPcopy Create free account
hub / github.com/Tiiny-AI/PowerInfer / set_content

Method set_content

examples/server/httplib.h:4932–4939  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4930}
4931
4932inline void Response::set_content(const char *s, size_t n,
4933 const std::string &content_type) {
4934 body.assign(s, n);
4935
4936 auto rng = headers.equal_range("Content-Type");
4937 headers.erase(rng.first, rng.second);
4938 set_header("Content-Type", content_type);
4939}
4940
4941inline void Response::set_content(const std::string &s,
4942 const std::string &content_type) {

Callers 2

mainFunction · 0.80
mainFunction · 0.80

Calls 3

assignMethod · 0.45
dataMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected