1#ifndef OSMIUM_OBJECT_POINTER_COLLECTION_HPP
2#define OSMIUM_OBJECT_POINTER_COLLECTION_HPP
47 template <
typename TBaseIterator,
typename TValue>
63 return *TBaseIterator::operator*();
67 return &*TBaseIterator::operator*();
115 template <
typename TCompare>
116 void sort(TCompare&& compare) {
117 std::stable_sort(
m_objects.begin(),
m_objects.end(), std::forward<TCompare>(compare));
125 template <
typename TEqual>
127 const auto last = std::unique(
m_objects.begin(),
m_objects.end(), std::forward<TEqual>(equal));
145 std::size_t
size() const noexcept {
Definition: object.hpp:64
Definition: object_pointer_collection.hpp:91
void sort(TCompare &&compare)
Definition: object_pointer_collection.hpp:116
void osm_object(osmium::OSMObject &object)
Definition: object_pointer_collection.hpp:107
std::vector< osmium::OSMObject * >::iterator ptr_iterator
Definition: object_pointer_collection.hpp:100
iterator end()
Definition: object_pointer_collection.hpp:158
ptr_iterator ptr_end() noexcept
Access to end of pointer vector.
Definition: object_pointer_collection.hpp:176
void unique(TEqual &&equal)
Definition: object_pointer_collection.hpp:126
ptr_iterator ptr_begin() noexcept
Access to begin of pointer vector.
Definition: object_pointer_collection.hpp:171
const_iterator cend() const
Definition: object_pointer_collection.hpp:166
void clear()
Clear the collection,.
Definition: object_pointer_collection.hpp:150
std::size_t size() const noexcept
Definition: object_pointer_collection.hpp:145
const_iterator cbegin() const
Definition: object_pointer_collection.hpp:162
bool empty() const noexcept
Definition: object_pointer_collection.hpp:136
ObjectPointerCollection()=default
iterator begin()
Definition: object_pointer_collection.hpp:154
std::vector< osmium::OSMObject * > m_objects
Definition: object_pointer_collection.hpp:93
Definition: handler.hpp:71
Definition: object_pointer_collection.hpp:48
TValue value_type
Definition: object_pointer_collection.hpp:53
pointer operator->() const noexcept
Definition: object_pointer_collection.hpp:66
value_type & reference
Definition: object_pointer_collection.hpp:56
value_type * pointer
Definition: object_pointer_collection.hpp:55
std::ptrdiff_t difference_type
Definition: object_pointer_collection.hpp:54
reference operator*() const noexcept
Definition: object_pointer_collection.hpp:62
std::random_access_iterator_tag iterator_category
Definition: object_pointer_collection.hpp:52
indirect_iterator(TBaseIterator it)
Definition: object_pointer_collection.hpp:58
Namespace for everything in the Osmium library.
Definition: assembler.hpp:53