Refactor RestService interfaces.

This commit is contained in:
Adam Gu
2018-08-24 16:51:08 +08:00
parent e9096d4e53
commit a863b379d0
10 changed files with 227 additions and 265 deletions
+3 -3
View File
@@ -24,6 +24,9 @@ class UrlQuery {
UrlQuery() = default;
// The query string should be key value pairs separated by '&'.
explicit UrlQuery(const std::string& str);
// Construct from key-value pairs.
explicit UrlQuery(const std::map<std::string, std::string>& map);
@@ -84,9 +87,6 @@ class Url {
// Split a path into its hierarchical components.
static std::vector<std::string> SplitPath(const std::string& path);
// Split query string into key-value parameters.
static void SplitQuery(const std::string& str, UrlQuery* query);
private:
void Init(const std::string& str);