![]() |
MantisBase v0.4.9
|
Core type aliases, handler signatures, and the MbAppMixin DI mixin. More...
#include <nlohmann/json.hpp>#include <functional>#include <string>#include <vector>#include <filesystem>#include "../export.h"

Go to the source code of this file.
Classes | |
| class | mb::MbAppMixin |
| Non-owning access to the active MantisBase from DI-aware types. More... | |
Namespaces | |
| namespace | mb |
Macros | |
| #define | REQUEST_HANDLED MbHandlerResponse::Handled; |
| #define | REQUEST_PENDING MbHandlerResponse::Unhandled; |
Typedefs | |
| using | mb::MbHandlerFn = std::function<void(MbRequest&, MbResponse&)> |
| Standard route handler (request, response). | |
| using | mb::MbMiddlewareFn = std::function<MbHandlerResponse(MbRequest&, MbResponse&)> |
| using | mb::MbMiddlewares = std::vector<MbMiddlewareFn> |
| using | mb::MbMethod = std::string |
| using | mb::MbPath = std::string |
| using | mb::MbRouteKey = std::pair<MbMethod, MbPath> |
| Route lookup key: HTTP method + path pattern. | |
Enumerations | |
| enum class | mb::MbHandlerResponse { mb::Handled , mb::Unhandled } |
| Middleware short-circuit result: stop or continue the chain. More... | |
Core type aliases, handler signatures, and the MbAppMixin DI mixin.
Defines the function types used throughout routing (HandlerFn, MiddlewareFn) and the non-owning MantisBase reference mixin inherited by request/response wrappers and service classes.
| #define REQUEST_HANDLED MbHandlerResponse::Handled; |
| #define REQUEST_PENDING MbHandlerResponse::Unhandled; |