fhq-server  v0.2.33
Documentation for fhq-server. FreeHackQuest is an open source platform for competitions of computer security.
Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
WsjcppLightWebHttpRequest Class Reference

#include <wsjcpp_light_web_http_request.h>

Public Member Functions

 WsjcppLightWebHttpRequest (int nSockFd, const std::string &sAddress)
 
 ~WsjcppLightWebHttpRequest ()
 
int getSockFd () const
 
std::string getUniqueId () const
 
void appendRecieveRequest (const std::string &sRequestPart)
 
bool isEnoughAppendReceived () const
 
std::string getAddress () const
 
std::string getRequestType () const
 
std::string getRequestPath () const
 
std::string getRequestBody () const
 
std::string getRequestHttpVersion () const
 
const std::vector< WsjcppLightWebHttpRequestQueryValue > & getRequestQueryParams ()
 

Private Types

enum  EnumParserState { START, BODY, ENDED }
 

Private Member Functions

void parseFirstLine (const std::string &sHeader)
 

Private Attributes

std::string TAG
 
int m_nSockFd
 
bool m_bClosed
 
EnumParserState m_nParserState
 
std::vector< std::string > m_vHeaders
 
int m_nContentLength
 
std::string m_sUniqueId
 
std::string m_sRequest
 
std::string m_sAddress
 
std::string m_sRequestType
 
std::string m_sRequestPath
 
std::string m_sRequestBody
 
std::vector< WsjcppLightWebHttpRequestQueryValuem_vRequestQueryParams
 
std::string m_sRequestHttpVersion
 
std::string m_sResponseCacheControl
 
std::string m_sLastModified
 

Member Enumeration Documentation

◆ EnumParserState

Enumerator
START 
BODY 
ENDED 

Constructor & Destructor Documentation

◆ WsjcppLightWebHttpRequest()

WsjcppLightWebHttpRequest::WsjcppLightWebHttpRequest ( int  nSockFd,
const std::string &  sAddress 
)

◆ ~WsjcppLightWebHttpRequest()

WsjcppLightWebHttpRequest::~WsjcppLightWebHttpRequest ( )
inline

Member Function Documentation

◆ appendRecieveRequest()

void WsjcppLightWebHttpRequest::appendRecieveRequest ( const std::string &  sRequestPart)

◆ getAddress()

std::string WsjcppLightWebHttpRequest::getAddress ( ) const

◆ getRequestBody()

std::string WsjcppLightWebHttpRequest::getRequestBody ( ) const

◆ getRequestHttpVersion()

std::string WsjcppLightWebHttpRequest::getRequestHttpVersion ( ) const

◆ getRequestPath()

std::string WsjcppLightWebHttpRequest::getRequestPath ( ) const

◆ getRequestQueryParams()

const std::vector< WsjcppLightWebHttpRequestQueryValue > & WsjcppLightWebHttpRequest::getRequestQueryParams ( )

◆ getRequestType()

std::string WsjcppLightWebHttpRequest::getRequestType ( ) const

◆ getSockFd()

int WsjcppLightWebHttpRequest::getSockFd ( ) const

◆ getUniqueId()

std::string WsjcppLightWebHttpRequest::getUniqueId ( ) const

◆ isEnoughAppendReceived()

bool WsjcppLightWebHttpRequest::isEnoughAppendReceived ( ) const

◆ parseFirstLine()

void WsjcppLightWebHttpRequest::parseFirstLine ( const std::string &  sHeader)
private

Member Data Documentation

◆ m_bClosed

bool WsjcppLightWebHttpRequest::m_bClosed
private

◆ m_nContentLength

int WsjcppLightWebHttpRequest::m_nContentLength
private

◆ m_nParserState

EnumParserState WsjcppLightWebHttpRequest::m_nParserState
private

◆ m_nSockFd

int WsjcppLightWebHttpRequest::m_nSockFd
private

◆ m_sAddress

std::string WsjcppLightWebHttpRequest::m_sAddress
private

◆ m_sLastModified

std::string WsjcppLightWebHttpRequest::m_sLastModified
private

◆ m_sRequest

std::string WsjcppLightWebHttpRequest::m_sRequest
private

◆ m_sRequestBody

std::string WsjcppLightWebHttpRequest::m_sRequestBody
private

◆ m_sRequestHttpVersion

std::string WsjcppLightWebHttpRequest::m_sRequestHttpVersion
private

◆ m_sRequestPath

std::string WsjcppLightWebHttpRequest::m_sRequestPath
private

◆ m_sRequestType

std::string WsjcppLightWebHttpRequest::m_sRequestType
private

◆ m_sResponseCacheControl

std::string WsjcppLightWebHttpRequest::m_sResponseCacheControl
private

◆ m_sUniqueId

std::string WsjcppLightWebHttpRequest::m_sUniqueId
private

◆ m_vHeaders

std::vector<std::string> WsjcppLightWebHttpRequest::m_vHeaders
private

◆ m_vRequestQueryParams

std::vector<WsjcppLightWebHttpRequestQueryValue> WsjcppLightWebHttpRequest::m_vRequestQueryParams
private

◆ TAG

std::string WsjcppLightWebHttpRequest::TAG
private

The documentation for this class was generated from the following files: