1 #ifndef OSMIUM_TAGS_MATCHER_HPP 2 #define OSMIUM_TAGS_MATCHER_HPP 39 #include <type_traits> 74 template <
typename TKey,
typename X =
typename std::enable_if<
75 std::is_convertible<TKey, osmium::StringMatcher>::value,
void>
::type>
77 m_key_matcher(
std::forward<TKey>(key_matcher)),
89 template <
typename TKey,
typename TValue,
90 typename std::enable_if<std::is_convertible<TKey, osmium::StringMatcher>::value,
int>
::type = 0,
91 typename std::enable_if<std::is_convertible<TValue, osmium::StringMatcher>::value,
int>::type = 0>
92 TagMatcher(TKey&& key_matcher, TValue&& value_matcher,
bool invert =
false) :
93 m_key_matcher(
std::forward<TKey>(key_matcher)),
94 m_value_matcher(
std::forward<TValue>(value_matcher)),
95 m_has_value_matcher(true),
104 bool operator()(
const char* key,
const char* value)
const noexcept {
124 for (
const auto& tag : tags) {
125 if (
operator()(tag)) {
136 #endif // OSMIUM_TAGS_MATCHER_HPP bool has_value_matcher() const noexcept
Definition: matcher.hpp:64
TagMatcher()
Definition: matcher.hpp:59
type
Definition: entity_bits.hpp:63
bool operator()(const osmium::TagList &tags) const noexcept
Definition: matcher.hpp:123
Definition: location.hpp:551
TagMatcher(TKey &&key_matcher, TValue &&value_matcher, bool invert=false)
Definition: matcher.hpp:92
Namespace for everything in the Osmium library.
Definition: assembler.hpp:53
bool operator()(const char *key, const char *value) const noexcept
Definition: matcher.hpp:104
Definition: string_matcher.hpp:73
Definition: matcher.hpp:47
bool operator()(const osmium::Tag &tag) const noexcept
Definition: matcher.hpp:114
bool m_result
Definition: matcher.hpp:52
Definition: string_matcher.hpp:84
TagMatcher(TKey &&key_matcher)
Definition: matcher.hpp:76
bool m_has_value_matcher
Definition: matcher.hpp:51
osmium::StringMatcher m_value_matcher
Definition: matcher.hpp:50
osmium::StringMatcher m_key_matcher
Definition: matcher.hpp:49