1 #ifndef OSMIUM_OSM_RELATION_HPP
2 #define OSMIUM_OSM_RELATION_HPP
50 template <
class>
class ObjectBuilder;
51 class RelationMemberListBuilder;
73 const unsigned char*
endpos()
const {
77 template <
class TMember>
88 unsigned const char*
next()
const {
107 m_flags(full ? 1 : 0) {
136 const char*
role() const noexcept {
160 size_type
size() const noexcept {
172 OSMObject(sizeof(Relation), osmium::item_type::relation) {
180 return osmium::detail::subitem_of_type<RelationMemberList>(
begin(),
end());
184 return osmium::detail::subitem_of_type<const RelationMemberList>(
cbegin(),
cend());
192 #endif // OSMIUM_OSM_RELATION_HPP
string_size_type m_role_size
Definition: relation.hpp:61
iterator end()
Definition: collection.hpp:127
Definition: collection.hpp:47
RelationMember & ref(object_id_type ref) noexcept
Definition: relation.hpp:114
uint64_t unsigned_object_id_type
Type for OSM object (node, way, or relation) IDs where we only allow positive IDs.
Definition: types.hpp:46
uint16_t m_flags
Definition: relation.hpp:60
RelationMemberList & members()
Definition: relation.hpp:179
const OSMObject & get_object() const
Definition: relation.hpp:144
RelationMemberList()
Definition: relation.hpp:156
item_type
Definition: item_type.hpp:43
Definition: relation.hpp:167
const_iterator cend() const
Definition: object.hpp:346
OSMObject & get_object()
Definition: relation.hpp:140
Definition: relation.hpp:150
iterator begin()
Definition: collection.hpp:123
double distance(const osmium::geom::Coordinates &c1, const osmium::geom::Coordinates &c2)
Definition: haversine.hpp:64
const_iterator cbegin() const
Definition: object.hpp:342
T padded_length(T length) noexcept
Definition: item.hpp:56
iterator end()
Definition: object.hpp:338
const RelationMemberList & members() const
Definition: relation.hpp:183
static constexpr osmium::item_type itemtype
Definition: relation.hpp:177
Definition: relation.hpp:54
int64_t object_id_type
Type for OSM object (node, way, or relation) IDs.
Definition: types.hpp:45
Namespace for everything in the Osmium library.
Definition: assembler.hpp:55
unsigned_object_id_type positive_ref() const noexcept
Definition: relation.hpp:119
Definition: collection.hpp:105
unsigned char * endpos()
Definition: relation.hpp:69
uint16_t string_size_type
Definition: types.hpp:58
unsigned const char * next() const
Definition: relation.hpp:88
item_type m_type
Definition: relation.hpp:59
item_type type() const noexcept
Definition: relation.hpp:128
RelationMember & operator=(const RelationMember &)=delete
bool full_member() const noexcept
Definition: relation.hpp:132
unsigned char * data() const noexcept
Definition: collection.hpp:85
void set_role_size(string_size_type size) noexcept
Definition: relation.hpp:96
object_id_type ref() const noexcept
Definition: relation.hpp:110
const char * role() const noexcept
Definition: relation.hpp:136
Definition: builder.hpp:186
RelationMember & set_ref(const osmium::object_id_type ref) noexcept
Definition: relation.hpp:123
Collection()
Definition: collection.hpp:115
object_id_type m_ref
Definition: relation.hpp:58
size_t size_type
Definition: relation.hpp:154
RelationMember(const object_id_type ref=0, const item_type type=item_type(), const bool full=false) noexcept
Definition: relation.hpp:104
static constexpr item_type collection_type
Definition: relation.hpp:102
const unsigned char * endpos() const
Definition: relation.hpp:73
unsigned char * next()
Definition: relation.hpp:80
Definition: osm_object_builder.hpp:135
RelationMember(const RelationMember &)=delete
Definition: object.hpp:58
size_type size() const noexcept
Definition: relation.hpp:160
iterator begin()
Definition: object.hpp:334