MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / addHeader

Method addHeader

Engine/source/app/net/httpObject.cpp:419–431  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

417}
418
419void HTTPObject::addHeader(const std::string &name, const std::string &value)
420{
421 std::string header = name + ": " + value;
422
423 //Formatting: Replace spaces with hyphens
424 size_t nameLen = name.size();
425 for (U32 i = 0; i < nameLen; i ++) {
426 if (header[i] == ' ')
427 header[i] = '-';
428 }
429
430 mHeaders = curl_slist_append(mHeaders, header.c_str());
431}
432
433void HTTPObject::get(const std::string &address, const std::string &uri, const std::string &query)
434{

Callers 2

DefineEngineMethodFunction · 0.45
writeMethod · 0.45

Calls 3

curl_slist_appendFunction · 0.85
sizeMethod · 0.45
c_strMethod · 0.45

Tested by

no test coverage detected