diff --git a/indexer/feature.cpp b/indexer/feature.cpp index 6877d86525..9ddf065588 100644 --- a/indexer/feature.cpp +++ b/indexer/feature.cpp @@ -351,6 +351,24 @@ string FeatureType::GetRoadNumber() const return m_params.ref; } +bool FeatureType::HasInternet() const +{ + bool res = false; + + ForEachType([&res](uint32_t type) + { + if (!res) + { + static const uint32_t t1 = classif().GetTypeByPath({"internet_access"}); + + ftype::TruncValue(type, 1); + res = (type == t1); + } + }); + + return res; +} + namespace { class DoCalcDistance diff --git a/indexer/feature.hpp b/indexer/feature.hpp index a676164075..999d5f3f83 100644 --- a/indexer/feature.hpp +++ b/indexer/feature.hpp @@ -261,6 +261,8 @@ public: uint8_t GetRank() const; uint32_t GetPopulation() const; string GetRoadNumber() const; + bool HasInternet() const; + inline feature::FeatureMetadata const & GetMetadata() const { return m_metadata; } inline feature::FeatureMetadata & GetMetadata() { return m_metadata; }