| 69 | } |
| 70 | |
| 71 | std::string encodeParameterMap(const ParameterMap& params) |
| 72 | { |
| 73 | ostringstream oss; |
| 74 | for (ParameterMap::const_iterator it=params.begin();it!=params.end();it++) |
| 75 | { |
| 76 | oss << it->first << "%" << it->second << "#"; |
| 77 | } |
| 78 | string res = oss.str(); |
| 79 | return res.substr(0,res.size()-1); |
| 80 | } |
| 81 | |
| 82 | ParameterMap decodeParameterMap(const std::string& thestr) |
| 83 | { |