tufao  1.3.0
An asynchronous web framework for C++ built on top of Qt
Tufao::HttpUpgradeRouter::Mapping Struct Reference

This class describes a request handler and a filter. More...

+ Collaboration diagram for Tufao::HttpUpgradeRouter::Mapping:

Public Member Functions

 Mapping (QRegularExpression path, Handler handler)
 Constructs a Mapping object using path as filter and handler as handler.
 
 Mapping ()=default
 Constructs an empty Mapping object.
 

Public Attributes

QRegularExpression path
 This attribute is used to filter requests based on the url's path component. More...
 
Handler handler
 

Detailed Description

This class describes a request handler and a filter.

The filter is very basic and only can select requests based on the url's path component.

The handlers return a boolean indicating whether it's able to handle the request. You can use this return value to overcome the simplistic nature of the provided filter.

Member Data Documentation

QRegularExpression Tufao::HttpUpgradeRouter::Mapping::path

This attribute is used to filter requests based on the url's path component.

It's a regular expression, so you have powerful control.


The documentation for this struct was generated from the following file: