| 135 | } |
| 136 | |
| 137 | bool RapidDeserializer::field( |
| 138 | const std::string& name, |
| 139 | const std::function<bool(dap::Deserializer*)>& cb) const { |
| 140 | if (!json()->IsObject()) { |
| 141 | return false; |
| 142 | } |
| 143 | auto it = json()->FindMember(name.c_str()); |
| 144 | if (it == json()->MemberEnd()) { |
| 145 | return cb(&NullDeserializer::instance); |
| 146 | } |
| 147 | RapidDeserializer d(&(it->value)); |
| 148 | return cb(&d); |
| 149 | } |
| 150 | |
| 151 | RapidSerializer::RapidSerializer() |
| 152 | : doc(new rapidjson::Document(rapidjson::kObjectType)), |
no test coverage detected