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

Function GetPath

libs/search/features_layer_path_finder.cpp:55–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53}
54
55bool GetPath(uint32_t id, vector<FeaturesLayer const *> const & layers, ParentGraph const & parent,
56 IntersectionResult & result)
57{
58 result.Clear();
59 if (layers.size() != parent.size() + 1)
60 return false;
61
62 size_t level = 0;
63 for (auto parentGraphLayer = parent.crbegin(); parentGraphLayer != parent.crend(); ++parentGraphLayer, ++level)
64 {
65 result.Set(layers[level]->m_type, id);
66 auto const it = parentGraphLayer->find(id);
67 if (it == parentGraphLayer->cend())
68 return false;
69 id = it->second;
70 }
71 result.Set(layers[level]->m_type, id);
72 return true;
73}
74
75bool MayHaveDelayedFeatures(FeaturesLayer const & layer)
76{

Callers 10

ProcessTileMethod · 0.85
UNIT_TESTFunction · 0.85
UNIT_CLASS_TESTFunction · 0.85
DeleteFromDiskMethod · 0.85
SyncWithDiskMethod · 0.85
DeleteFromDiskMethod · 0.85
ValidateIntegrityMethod · 0.85
UNIT_TESTFunction · 0.85

Calls 5

ClearMethod · 0.45
sizeMethod · 0.45
SetMethod · 0.45
findMethod · 0.45
cendMethod · 0.45

Tested by 3

UNIT_TESTFunction · 0.68
UNIT_CLASS_TESTFunction · 0.68
UNIT_TESTFunction · 0.68