| 281 | // Private methods |
| 282 | |
| 283 | std::string Session::Reply::Get(const std::string& key) const |
| 284 | { |
| 285 | const auto& pos = keys.find(key); |
| 286 | if (pos == keys.end() || !pos->second.has_value()) { |
| 287 | throw std::runtime_error( |
| 288 | strprintf("Missing %s= in the reply to \"%s\"", key, request)); |
| 289 | } |
| 290 | return pos->second.value(); |
| 291 | } |
| 292 | |
| 293 | Session::Reply Session::SendRequestAndGetReply(const Sock& sock, |
| 294 | const std::string& request, |
no test coverage detected