1 #ifndef OSMIUM_AREA_MULTIPOLYGON_MANAGER_LEGACY_HPP 2 #define OSMIUM_AREA_MULTIPOLYGON_MANAGER_LEGACY_HPP 77 template <
typename TAssembler>
94 m_assembler_config(assembler_config) {
117 if ((!std::strcmp(type,
"multipolygon")) || (!std::strcmp(type,
"boundary"))) {
132 std::vector<const osmium::Way*> ways;
134 for (
const auto& member : relation.
members()) {
135 if (member.ref() != 0) {
137 assert(ways.back() !=
nullptr);
142 TAssembler assembler{m_assembler_config};
143 assembler(relation, ways, this->
buffer());
144 m_stats += assembler.stats();
165 TAssembler assembler{m_assembler_config};
166 assembler(way, this->
buffer());
167 m_stats += assembler.stats();
180 #endif // OSMIUM_AREA_MULTIPOLYGON_MANAGER_LEGACY_HPP WayNodeList & nodes()
Definition: way.hpp:89
const TagList & tags() const
Get the list of tags for this object.
Definition: object.hpp:327
const area_stats & stats() const noexcept
Definition: multipolygon_manager_legacy.hpp:101
type
Definition: entity_bits.hpp:63
void way(const osmium::Way &) const noexcept
Definition: handler.hpp:81
void complete_relation(const osmium::Relation &relation)
Definition: multipolygon_manager_legacy.hpp:131
RelationMemberList & members()
Get a reference to the member list.
Definition: relation.hpp:186
const assembler_config_type m_assembler_config
Definition: multipolygon_manager_legacy.hpp:81
bool new_relation(const osmium::Relation &relation) const
Definition: multipolygon_manager_legacy.hpp:109
osmium::memory::Buffer & buffer() noexcept
Access the output buffer.
Definition: relations_manager.hpp:255
Definition: relation.hpp:168
const_iterator cbegin() const noexcept
Definition: collection.hpp:164
MultipolygonManagerLegacy(const assembler_config_type &assembler_config)
Definition: multipolygon_manager_legacy.hpp:93
Definition: entity_bits.hpp:72
size_type size() const noexcept
Definition: collection.hpp:152
Definition: multipolygon_manager_legacy.hpp:78
Definition: relation.hpp:57
Namespace for everything in the Osmium library.
Definition: assembler.hpp:53
void relation(const osmium::Relation &relation)
Definition: relations_manager.hpp:484
Definition: location.hpp:53
const_iterator cend() const noexcept
Definition: collection.hpp:168
const osmium::Way * get_member_way(osmium::object_id_type id) const noexcept
Definition: relations_manager.hpp:209
osmium::Location & location() noexcept
Definition: node_ref.hpp:85
bool ends_have_same_location() const
Definition: way.hpp:142
const NodeRef & front() const noexcept
Definition: node_ref_list.hpp:126
const NodeRef & back() const noexcept
Definition: node_ref_list.hpp:138
Definition: relations_manager.hpp:301
area_stats m_stats
Definition: multipolygon_manager_legacy.hpp:83
const char * get_value_by_key(const char *key, const char *default_value=nullptr) const noexcept
Definition: tag.hpp:137
typename TAssembler::config_type assembler_config_type
Definition: multipolygon_manager_legacy.hpp:80
size_type size() const noexcept
Definition: node_ref_list.hpp:83
void way_not_in_any_relation(const osmium::Way &way)
Definition: multipolygon_manager_legacy.hpp:154