HTTP support improvements:

* RFC2616 compliance
* Case insensitive equality, inequality operators for strings
* Improvements to http::parser
* Tidy up HTTP method enumeration
This commit is contained in:
Vinnie Falco
2014-07-31 15:45:27 -07:00
parent df32f27762
commit 5b8bb822ba
11 changed files with 1389 additions and 262 deletions

View File

@@ -21,6 +21,7 @@
#define BEAST_HTTP_METHOD_H_INCLUDED
#include <memory>
#include <string>
namespace beast {
namespace http {
@@ -65,6 +66,20 @@ enum class method_t
http_purge
};
std::string
to_string (method_t m);
template <class Stream>
Stream&
operator<< (Stream& s, method_t m)
{
return s << to_string(m);
}
/** Returns the string corresponding to the numeric HTTP status code. */
std::string
status_text (int status);
}
}