The query component of a URI.
More...
#include <URI.hh>
|
| | URIQuery () |
| | Constructor.
|
| | URIQuery (const std::string &_str) |
| | Construct a URIQuery object from a string.
|
| | URIQuery (const URIQuery &_query) |
| | Copy constructor.
|
| virtual | ~URIQuery () |
| | Destructor.
|
| void | Clear () |
| | Remove all values of the query.
|
| void | Insert (const std::string &_key, const std::string &_value) |
| | Get this query with a new _key=_value pair added.
|
| URIQuery & | operator= (const URIQuery &_query) |
| | Equal operator.
|
| bool | operator== (const URIQuery &_query) const |
| | Return true if the two queries contain the same values.
|
| bool | Parse (const std::string &_string) |
| | Parse a string as URIQuery.
|
| std::string | Str (const std::string &_delim="&") const |
| | Get the query as a string.
|
| bool | Valid () const |
| | Check if this is a valid URI query.
|
|
| static bool | Valid (const std::string &_str) |
| | Check if a string is a valid URI query.
|
The query component of a URI.
◆ URIQuery() [1/3]
◆ URIQuery() [2/3]
Construct a URIQuery object from a string.
- Parameters
-
◆ URIQuery() [3/3]
Copy constructor.
- Parameters
-
| [in] | _query | Another query component |
References URIQuery().
◆ ~URIQuery()
◆ Clear()
Remove all values of the query.
◆ Insert()
| void Insert |
( |
const std::string & | _key, |
|
|
const std::string & | _value ) |
Get this query with a new _key=_value pair added.
- Parameters
-
| [in] | _key | Key of the query. |
| [in] | _value | Value of the query. |
◆ operator=()
Equal operator.
- Parameters
-
- Returns
- Itself.
References URIQuery().
◆ operator==()
| bool operator== |
( |
const URIQuery & | _query | ) |
const |
Return true if the two queries contain the same values.
- Parameters
-
| [in] | _query | A URI query to compare. return True if the queries match. |
References URIQuery().
◆ Parse()
| bool Parse |
( |
const std::string & | _string | ) |
|
Parse a string as URIQuery.
- Parameters
-
- Returns
- True if the string can be parsed as a URIQuery.
◆ Str()
| std::string Str |
( |
const std::string & | _delim = "&" | ) |
const |
Get the query as a string.
- Parameters
-
| [in] | _delim | Delimiter used to separate each tuple of the query. |
- Returns
- The query as a string, with each key,value pair separated by _delim.
◆ Valid() [1/2]
Check if this is a valid URI query.
- Returns
- True if this can be parsed as a URI query.
◆ Valid() [2/2]
| bool Valid |
( |
const std::string & | _str | ) |
|
|
static |
Check if a string is a valid URI query.
- Parameters
-
| [in] | _str | The string to check. |
- Returns
- True if the string can be parsed as a URI query.
The documentation for this class was generated from the following file: