#include <Route.h>
Public Member Functions | |
| Route (const std::string &method, const std::string &relativeMountPath, const std::shared_ptr< Dispatcher > &dispatcher) | |
| std::list< std::string > | getRoute (const std::string &parentMountPath, bool strictRouting) const |
| Route & | use (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | use (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | use (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | use (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | all (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | all (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | all (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | all (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | get (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | get (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | get (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | get (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | put (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | put (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | put (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | put (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | post (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | post (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | post (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | post (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | del (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | del (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | del (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | del (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | connect (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | connect (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | connect (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | connect (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | options (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | options (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | options (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | options (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | trace (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | trace (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | trace (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | trace (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | patch (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | patch (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | patch (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | patch (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
| Route & | head (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda) const |
| Route & | head (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda) const |
| template<typename... Lambdas> | |
| Route & | head (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &)> &lambda, Lambdas... lambdas) const |
| template<typename... Lambdas> | |
| Route & | head (const std::function< void(const std::shared_ptr< Request > &, const std::shared_ptr< Response > &, Next &)> &lambda, Lambdas... lambdas) const |
Private Member Functions | |
| Route () | |
| bool | dispatch (Controller &controller, bool strictRouting, bool caseInsensitiveRouting, bool mergeParams) |
| bool | dispatchNext (Controller &controller, bool strictRouting, bool caseInsensitiveRouting, bool mergeParams) |
Private Attributes | |
| MountPoint | mountPoint |
| std::shared_ptr< Dispatcher > | dispatcher |
Friends | |
| class | dispatcher::RouterDispatcher |
| class | Dispatcher |
| class | RootRoute |
| class | Controller |
| express::Route::Route | ( | const std::string & | method, |
| const std::string & | relativeMountPath, | ||
| const std::shared_ptr< Dispatcher > & | dispatcher ) |
Definition at line 77 of file Route.cpp.
References dispatcher, express::MountPoint::MountPoint(), and mountPoint.
|
private |
Definition at line 72 of file Route.cpp.
References dispatcher, express::MountPoint::MountPoint(), and mountPoint.
|
private |
Definition at line 82 of file Route.cpp.
References express::Dispatcher::dispatch(), dispatcher, express::Controller::dispatchNext(), mountPoint, and express::Controller::setCurrentRoute().
Referenced by express::dispatcher::RouterDispatcher::dispatch(), express::RootRoute::dispatch(), and express::Dispatcher::dispatchNext().
|
private |
Definition at line 94 of file Route.cpp.
References dispatcher, and express::Dispatcher::dispatchNext().
Referenced by express::Controller::dispatchNext().
| std::list< std::string > express::Route::getRoute | ( | const std::string & | parentMountPath, |
| bool | strictRouting ) const |
Definition at line 98 of file Route.cpp.
References dispatcher, express::Dispatcher::getRoutes(), and mountPoint.
Referenced by express::dispatcher::ApplicationDispatcher::getRoutes(), express::dispatcher::MiddlewareDispatcher::getRoutes(), and express::dispatcher::RouterDispatcher::getRoutes().
|
friend |
|
private |
Definition at line 94 of file Route.h.
Referenced by dispatch(), dispatchNext(), express::RootRoute::getCaseInsensitiveRouting(), express::RootRoute::getDispatcher(), express::RootRoute::getMergeParams(), getRoute(), express::RootRoute::getRoutes(), express::RootRoute::getStrictRouting(), Route(), Route(), express::RootRoute::routes(), express::RootRoute::setCaseInsensitiveRouting(), express::RootRoute::setMergeParams(), and express::RootRoute::setStrictRouting().
|
private |
Definition at line 93 of file Route.h.
Referenced by dispatch(), getRoute(), express::RootRoute::getRoutes(), Route(), and Route().