move some methods from App to Request
methods moved: SetEnv(), ReadEnvVariables(), ReadEnvRemoteIP(), CheckSSL(), SetSubdomain() while here: - add the rest of http methods: put, connect, trace, patch
This commit is contained in:
@@ -161,7 +161,7 @@ public:
|
||||
the HTTP method
|
||||
!! IMPROVE ME add the rest methods here
|
||||
*/
|
||||
enum Method { get, post, head, delete_, options, unknown_method } method;
|
||||
enum Method { get, head, post, put, delete_, connect, options, trace, patch, unknown_method } method;
|
||||
|
||||
|
||||
/*
|
||||
@@ -519,6 +519,20 @@ public:
|
||||
|
||||
void FinishRequest();
|
||||
|
||||
|
||||
void SetEnv(const char * name, std::wstring & env);
|
||||
void ReadEnvVariables();
|
||||
void ReadEnvRemoteIP();
|
||||
|
||||
static Method CheckRequestMethod(const wchar_t * name);
|
||||
void CheckRequestMethod();
|
||||
|
||||
void CheckSSL();
|
||||
void SetSubdomain();
|
||||
|
||||
static void PutMethodName(Request::Method method, pt::Stream & stream);
|
||||
void PutMethodName(pt::Stream & stream);
|
||||
|
||||
private:
|
||||
|
||||
Config * config;
|
||||
@@ -534,6 +548,8 @@ private:
|
||||
std::string aheader_name, aheader_value;
|
||||
std::wstring cookie_id_string;
|
||||
std::string send_data_buf;
|
||||
std::wstring http_header_name;
|
||||
std::string http_header_8bit;
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user