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

Method DeleteCustomCountryVersion

libs/storage/storage.cpp:868–888  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

866}
867
868void Storage::DeleteCustomCountryVersion(LocalCountryFile const & localFile)
869{
870 CHECK_THREAD_CHECKER(m_threadChecker, ());
871
872 DeleteFromDiskWithIndexes(localFile, MapFileType::Map);
873 DeleteFromDiskWithIndexes(localFile, MapFileType::Diff);
874
875 auto it = m_localFilesForFakeCountries.find(localFile.GetCountryFile());
876 if (it != m_localFilesForFakeCountries.end())
877 {
878 m_localFilesForFakeCountries.erase(it);
879 return;
880 }
881
882 CountryId const & countryId = FindCountryId(localFile);
883 if (!IsLeaf(countryId))
884 {
885 LOG(LERROR, ("Removed files for an unknown country:", localFile));
886 return;
887 }
888}
889
890void Storage::NotifyStatusChanged(CountryId const & countryId)
891{

Callers 2

UNIT_CLASS_TESTFunction · 0.80
OnMapDeregisteredMethod · 0.80

Calls 4

findMethod · 0.45
endMethod · 0.45
eraseMethod · 0.45

Tested by 1

UNIT_CLASS_TESTFunction · 0.64