|
|
Donner
C++20 SVG rendering library
|
Returned by Selector::matches to indicate whether the selector matched, and if so, the specificity of the match. More...
#include "donner/css/selectors/ComplexSelector.h"
Public Member Functions | |
| operator bool () const | |
| Returns true if the selector matched. | |
Static Public Member Functions | |
| static constexpr SelectorMatchResult | None () |
| Create a SelectorMatchResult indicating that the selector did not match. | |
| static constexpr SelectorMatchResult | Match (Specificity specificity) |
| Create a SelectorMatchResult indicating that the selector matched, with the given specificity. | |
Public Attributes | |
| bool | matched = false |
| True if the selector matched. | |
| Specificity | specificity |
| The specificity of the match, if matched. | |
Returned by Selector::matches to indicate whether the selector matched, and if so, the specificity of the match.
The bool operator can be used to check if the selector matched:
To construct, use the static methods: None() and Match().
|
inlinestaticconstexpr |
Create a SelectorMatchResult indicating that the selector matched, with the given specificity.
| specificity | The specificity of the match. |