1 #ifndef SRC_RESOURCEPARAMETERS_HPP_ 2 #define SRC_RESOURCEPARAMETERS_HPP_ 17 class ResourceResolver;
46 void setQueryParameter(std::string
const &name, std::string
const &value);
47 void resetPathParameters();
48 void setPathParameter(
size_t idx, std::string
const &val);
52 std::vector<std::string> _pathParams;
54 std::vector<std::pair<std::string, std::string>> _queryParams;
bool getQueryParameter(std::string const &name, std::string &value)
Returns an HTTP query parameter.
Definition: ResourceParameters.cpp:48
The ResourceParameters provide access to the parameters passed in the URI.
Definition: ResourceParameters.hpp:31
size_t getQueryParameterCount(bool unique=false)
Returns the number of query parameters.
Definition: ResourceParameters.cpp:67
std::vector< std::pair< std::string, std::string > >::iterator beginQueryParameters()
Provides iterator access to the query parameters.
Definition: ResourceParameters.cpp:98
This class is used internally to resolve a string URL to the corresponding HTTPNode.
Definition: ResourceResolver.hpp:22
bool getPathParameter(size_t const idx, std::string &value)
Checks for the existence of a path parameter and returns it as string.
Definition: ResourceParameters.cpp:129
bool isQueryParameterSet(std::string const &name)
Checks whether a specific HTTPS query parameter is set.
Definition: ResourceParameters.cpp:24
std::vector< std::pair< std::string, std::string > >::iterator endQueryParameters()
Counterpart to beginQueryParameters() for iterating over query parameters.
Definition: ResourceParameters.cpp:105
Definition: ConnectionContext.cpp:3