blob: 511025647aec21e54f991e850e077cd7539b9219 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
#include "generator/filter_collection.hpp"
#include "generator/feature_builder.hpp"
#include "generator/osm_element.hpp"
#include <algorithm>
using namespace feature;
namespace generator
{
bool FilterCollection::IsAccepted(OsmElement const & element)
{
return std::all_of(std::begin(m_collection), std::end(m_collection), [&] (auto & filter) {
return filter->IsAccepted(element);
});
}
bool FilterCollection::IsAccepted(FeatureBuilder const & feature)
{
return std::all_of(std::begin(m_collection), std::end(m_collection), [&] (auto & filter) {
return filter->IsAccepted(feature);
});
}
} // namespace generator
|