18 RequestMapper::~RequestMapper() {
27 QString path = request->
path();
29 #define ROUTER(adresa, trida) \ 30 if (path.startsWith(adresa)) { \ 31 HttpRequestHandler *controller = new trida (connection()); \ 32 controller->service(request, response); \ 38 HttpRequestHandler::service(request,
response);
HttpResponse * response()
Returns new instance of HttpResponse class.
QString path() const
Returns path of the request (/files/index.html)
Processes requests with path /example.
Name space for own application HTTP server.
void flush()
Writes last part of the response and closes the socket when possible.
Response to HTTP request - headers, cookies and body.
Processes incoming requests.
void service(HobrasoftHttpd::HttpRequest *request, HobrasoftHttpd::HttpResponse *response)
Processes the request.
Processes HTTP request, parses headers, body and files sent by HTTP protocol.
Namespace of HTTP server.
One single connection to http server.