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

Method Get

libs/search/categories_cache.cpp:18–28  ·  view source on GitHub ↗

CategoriesCache ---------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

16
17// CategoriesCache ---------------------------------------------------------------------------------
18CBV CategoriesCache::Get(MwmContext const & context)
19{
20 auto const id = context.m_handle.GetId();
21 auto const it = m_cache.find(id);
22 if (it != m_cache.cend())
23 return it->second;
24
25 auto cbv = Load(context);
26 m_cache[id] = cbv;
27 return cbv;
28}
29
30CBV CategoriesCache::Load(MwmContext const & context) const
31{

Callers

nothing calls this directly

Calls 4

LoadFunction · 0.50
GetIdMethod · 0.45
findMethod · 0.45
cendMethod · 0.45

Tested by

no test coverage detected