12 #include <boost/unordered/unordered_set.hpp>
13 #include <boost/tuple/tuple.hpp>
15 #include <tbb/spin_mutex.h>
22 namespace MAKVRinTerra
28 typedef boost::unordered_set<DtFeatureGeometry::Hash>
HashSet;
32 Mutex::scoped_lock lock(myMutex);
33 return myHashSet.find(g.
hash()) != myHashSet.end();
38 return insert(g.
hash());
41 bool insert(
const std::string& h)
43 HashSet::iterator iter;
46 Mutex::scoped_lock lock(myMutex);
47 boost::tie(iter, inserted) = myHashSet.insert(h);
75 boost::optional<std::string> attr = feature.template attributeAs<std::string>(
"MAK_FID");
85 return !
insert(feature.geometry());
90 if (!const_cast<DtFeatureDuplicateRemover*>(
this)->
isDuplicate(feature))
104 template <
typename F>
111 typedef boost::shared_ptr<DtFeatureDuplicateRemover<F> >
BasePtr;
125 (*myRemover)(feature);
143 template <
typename FS>
145 :
public FS::ScopedWrapper
149 typedef typename FS::ScopedWrapper
Parent;
175 const boost::optional<DtFeatureGeometry>& geom,
178 std::auto_ptr<FS> fs(Parent::filter(query, geom, load));