MCPcopy Create free account
hub / github.com/comaps/comaps / ForEachWayFromFile

Function ForEachWayFromFile

generator/routing_helpers.cpp:15–26  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13
14template <class ToDo>
15void ForEachWayFromFile(std::string const & filename, ToDo && toDo)
16{
17 using namespace generator;
18 CHECK(ForEachOsmId2FeatureId(filename,
19 [&](CompositeId const & compositeOsmId, uint32_t featureId)
20 {
21 auto const osmId = compositeOsmId.m_mainId;
22 if (osmId.GetType() == base::GeoObjectId::Type::ObsoleteOsmWay)
23 toDo(featureId, osmId);
24 }),
25 ("Can't load osm id mapping from", filename));
26}
27
28void AddFeatureId(base::GeoObjectId osmId, uint32_t featureId, OsmIdToFeatureIds & osmIdToFeatureIds)
29{

Calls 2

ForEachOsmId2FeatureIdFunction · 0.85
GetTypeMethod · 0.45

Tested by

no test coverage detected