/
renath
/
organicmaps
Обзор
Документация
Войти
/
renath
/
organicmaps
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
generator/translator_collection.cpp
41 строка
983 B
Viktor Govako
[generator] Collect addr:interpolation features.
22 ноя 2023, 18:39
22 ноя 2023, 18:39
954716b
Код
Авторство
О чём код?
#include "generator/translator_collection.hpp" #include "generator/osm_element.hpp" #include "base/stl_helpers.hpp" namespace generator { std::shared_ptr<TranslatorInterface> TranslatorCollection::Clone() const { auto p = std::make_shared<TranslatorCollection>(); for (auto const & c : m_collection) p->Append(c->Clone()); return p; } void TranslatorCollection::Emit(OsmElement const & element) { for (auto & t : m_collection) t->Emit(element); } void TranslatorCollection::Finish() { for (auto & t : m_collection) t->Finish(); } bool TranslatorCollection::Save() { return base::AllOf(m_collection, [](auto & t) { return t->Save(); }); } void TranslatorCollection::MergeInto(TranslatorCollection & other) const { auto & otherCollection = other.m_collection; CHECK_EQUAL(m_collection.size(), otherCollection.size(), ()); for (size_t i = 0; i < m_collection.size(); ++i) otherCollection[i]->Merge(*m_collection[i]); } } // namespace generator