mirror of
https://github.com/Relintai/rcpp_framework.git
synced 2025-05-02 13:47:56 +02:00
Added a session pointer to request.
This commit is contained in:
parent
2521c28a9a
commit
9e6645bad6
@ -3,6 +3,8 @@
|
|||||||
#include "core/http/cookie.h"
|
#include "core/http/cookie.h"
|
||||||
#include "web_application.h"
|
#include "web_application.h"
|
||||||
|
|
||||||
|
#include "http_session.h"
|
||||||
|
|
||||||
const std::string &Request::get_cookie(const std::string &key) {
|
const std::string &Request::get_cookie(const std::string &key) {
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -73,6 +75,7 @@ void Request::send_error(int error_code) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void Request::reset() {
|
void Request::reset() {
|
||||||
|
session = nullptr;
|
||||||
application = nullptr;
|
application = nullptr;
|
||||||
current_middleware_index = 0;
|
current_middleware_index = 0;
|
||||||
middleware_stack = nullptr;
|
middleware_stack = nullptr;
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
|
|
||||||
class WebApplication;
|
class WebApplication;
|
||||||
class Cookie;
|
class Cookie;
|
||||||
|
class HTTPSession;
|
||||||
|
|
||||||
class Request {
|
class Request {
|
||||||
public:
|
public:
|
||||||
@ -33,6 +34,7 @@ public:
|
|||||||
|
|
||||||
bool connection_closed;
|
bool connection_closed;
|
||||||
|
|
||||||
|
HTTPSession *session;
|
||||||
std::map<std::string, Object*> data;
|
std::map<std::string, Object*> data;
|
||||||
|
|
||||||
virtual const std::string &get_cookie(const std::string &key);
|
virtual const std::string &get_cookie(const std::string &key);
|
||||||
|
Loading…
Reference in New Issue
Block a user