static func getReasonPhrase()

This commit is contained in:
Talyx
2022-01-29 14:16:41 +03:00
parent 880af6cd6a
commit 087b16546e
2 changed files with 6 additions and 4 deletions

View File

@@ -94,6 +94,8 @@ void Response::methodGet(void)
//-------------------------------------------------GET/SET---------------------------------------
std::map<std::string, std::string> Response::_errorCode;
void Response::initErrorCode(void)
{
_errorCode["100"] = "Continue";

View File

@@ -14,7 +14,7 @@ private:
ServerConfig *_config;
private:
std::map<std::string, std::string> _errorCode;
static std::map<std::string, std::string> _errorCode;
private:
void methodGet(void);
@@ -25,15 +25,15 @@ private:
public:
std::string getClient(void);
std::string getBody(void);
std::string getReasonPhrase(std::string);
std::string getReasonPhrase(int);
static std::string getReasonPhrase(std::string);
static std::string getReasonPhrase(int);
std::string getErrorPage(int code);
void setData(Request, ServerConfig *);
public:
void OpenResponseFile(const char *path);
void initErrorCode(void);
void initErrorCode(void);
void generate();
Response();
~Response();