|
ReUseX
0.0.5
3D Point Cloud Processing for Building Reuse
|
Already-decoded query parameters, so handlers never touch crow::request. More...
#include <api.hpp>
Public Member Functions | |
| void | set (std::string key, std::string value) |
| std::optional< std::string > | find (std::string_view key) const |
| std::string | str (std::string_view key, std::string fallback) const |
String value, or fallback when absent/empty. | |
| long long | integer (std::string_view key, long long fallback) const |
Integer value, or fallback when absent. | |
| std::optional< bool > | boolean (std::string_view key) const |
| Boolean value, or nullopt when absent/empty. | |
Already-decoded query parameters, so handlers never touch crow::request.
| std::optional< bool > rux::gui::Params::boolean | ( | std::string_view | key | ) | const |
Boolean value, or nullopt when absent/empty.
Accepts true/false, 1/0, yes/no, any case. Anything else is a 400 rather than a silent false, because a filter that quietly inverts itself on a typo is worse than one that refuses.
| HttpError(400) | when present but not a recognised boolean. |
| std::optional< std::string > rux::gui::Params::find | ( | std::string_view | key | ) | const |
| long long rux::gui::Params::integer | ( | std::string_view | key, |
| long long | fallback ) const |
Integer value, or fallback when absent.
| HttpError(400) | when present but not a valid integer. |
| void rux::gui::Params::set | ( | std::string | key, |
| std::string | value ) |
| std::string rux::gui::Params::str | ( | std::string_view | key, |
| std::string | fallback ) const |
String value, or fallback when absent/empty.