Orbit Framework
An ultra-modern, asynchronous, cross-platform C++ Web Framework.
Loading...
Searching...
No Matches
App.hpp File Reference
Include dependency graph for App.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  server::App
 The main application class for the Orbit Framework. More...
 

Namespaces

namespace  server
 

Macros

#define ORBIT_DEFINE_ROUTER_TEMPLATES(METHOD)
 

Macro Definition Documentation

◆ ORBIT_DEFINE_ROUTER_TEMPLATES

#define ORBIT_DEFINE_ROUTER_TEMPLATES (   METHOD)
Value:
template <typename Handler> \
App& METHOD(const std::string& path, Handler&& handler) { \
return METHOD(path, routing::wrap_handler(std::forward<Handler>(handler))); \
} \
template <typename Handler> \
App& METHOD(const std::string& path, std::vector<routing::Middleware> mws, Handler&& handler) { \
return METHOD(path, std::move(mws), routing::wrap_handler(std::forward<Handler>(handler))); \
}
auto wrap_handler(Handler &&h) -> std::function< void(http::HttpRequest &, std::shared_ptr< http::ResponseWriter >)>
Definition HandlerWrapper.hpp:44