MCPcopy Create free account
hub / github.com/catboost/catboost / AddHeader

Method AddHeader

library/cpp/http/misc/httpreqdata.cpp:227–236  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

225}
226
227void TBaseServerRequestData::AddHeader(const TString& name, const TString& value) {
228 HeadersIn_[name] = value;
229
230 if (stricmp(name.data(), "Host") == 0) {
231 size_t hostLen = strcspn(value.data(), ":");
232 if (value[hostLen] == ':')
233 Port_ = value.substr(hostLen + 1);
234 Host_ = value.substr(0, hostLen);
235 }
236}
237
238void TBaseServerRequestData::SetPath(TString path) {
239 Path_ = std::move(path);

Callers 1

Y_UNIT_TESTFunction · 0.45

Calls 2

dataMethod · 0.45
substrMethod · 0.45

Tested by

no test coverage detected