Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: mbed-TFT-example-NCS36510 mbed-Accelerometer-example-NCS36510 mbed-Accelerometer-example-NCS36510
HTTPHeader.cpp
00001 #include "HTTPHeader.h" 00002 #include <stdlib.h> 00003 using std::map; 00004 using std::string; 00005 00006 HTTPHeader::HTTPHeader(): 00007 _status(HTTP_ERROR), 00008 _fields() 00009 { 00010 } 00011 00012 std::string HTTPHeader::getField(const std::string& name) 00013 { 00014 map<string,string>::iterator itor = _fields.find(name); 00015 if(itor == _fields.end()) 00016 return string(); 00017 return itor->second; 00018 } 00019 00020 int HTTPHeader::getBodyLength() 00021 { 00022 return atoi(getField("Content-Length").c_str()); 00023 } 00024
Generated on Tue Jul 12 2022 11:02:39 by
