| 98 | } |
| 99 | |
| 100 | bool BuildCitiesIdsForTesting(std::string const & dataPath) |
| 101 | { |
| 102 | CHECK(IsWorldMwm(dataPath), ()); |
| 103 | |
| 104 | ankerl::unordered_dense::map<uint32_t, uint64_t> mapping; |
| 105 | if (!ParseFeatureIdToTestIdMapping(dataPath, mapping)) |
| 106 | return false; |
| 107 | |
| 108 | ankerl::unordered_dense::map<uint32_t, base::GeoObjectId> mappingToGeoObjects; |
| 109 | for (auto const & entry : mapping) |
| 110 | { |
| 111 | // todo(@m) Make test ids a new source in base::GeoObjectId? |
| 112 | mappingToGeoObjects.emplace(entry.first, base::MakeOsmNode(entry.second)); |
| 113 | } |
| 114 | WriteCitiesIdsSectionToFile(dataPath, mappingToGeoObjects); |
| 115 | return true; |
| 116 | } |
| 117 | } // namespace generator |