예제 #1
0
 void Finish()
 {
   m_places.ForEach([this] (Place const & p)
   {
     m_emitter(p.GetFeature());
   });
 }
예제 #2
0
  void EmitFeatureBase(FeatureBuilder1 & ft, FeatureParams const & params)
  {
    ft.SetParams(params);
    if (ft.PreSerialize())
    {
      string addr;
      if (m_addrWriter && ftypes::IsBuildingChecker::Instance()(params.m_Types) && ft.FormatFullAddress(addr))
        m_addrWriter->Write(addr.c_str(), addr.size());

      static uint32_t const placeType = classif().GetTypeByPath({"place"});
      uint32_t const type = params.FindType(placeType, 1);

      if (type != ftype::GetEmptyValue() && !ft.GetName().empty())
      {
        m_places.ReplaceEqualInRect(Place(ft, type),
            [](Place const & p1, Place const & p2) { return p1.IsEqual(p2); },
            [](Place const & p1, Place const & p2) { return p1.IsBetterThan(p2); });
      }
      else
        m_emitter(ft);
    }
  }
예제 #3
0
파일: overlay.hpp 프로젝트: morsya/omim
 void forEach(Fn fn)
 {
   m_tree.ForEach(fn);
 }