diff --git a/src/endpoints_handlers/IExecutor.h b/src/endpoints_handlers/IExecutor.h index 7142c59..ab7a675 100644 --- a/src/endpoints_handlers/IExecutor.h +++ b/src/endpoints_handlers/IExecutor.h @@ -13,4 +13,25 @@ public: ) = 0; virtual ~IExecutor() = default; }; + +class IAuthorizable : public IExecutor +{ + IExecutor& next_executor_; +public: + IAuthorizable(IExecutor& next_executor): next_executor_(next_executor) + { + + } + + boost::beast::http::response operator ()( + boost::beast::http::request>&& req + ) override + { + // Логика проверки авторизации + // передать управление следующему executorу - возврат req + // посмотреть chain of responsibility, composite + // выбрасывать исключение здесь + return next_executor_(req); + } +}; }