19 #define EXPOSED_VECTOR_INTERFACE(InnerElement) \
20 using ExpVec = ExposedVector< InnerElement >; \
21 using ExpVec::ExposedVector; \
22 using value_type = typename ExpVec::value_type; \
23 using iterator = typename ExpVec::iterator; \
24 using const_iterator = typename ExpVec::const_iterator; \
25 using reverse_iterator = typename ExpVec::reverse_iterator; \
26 using const_reverse_iterator = typename ExpVec::const_reverse_iterator; \
27 using size_type = typename ExpVec::size_type; \
28 using pointer = typename ExpVec::pointer; \
29 using reference = typename ExpVec::reference; \
30 using const_reference = typename ExpVec::const_reference; \
31 using difference_type = typename ExpVec::difference_type; \
53 template<
class VectorElement>
66 using pointer =
typename VecMember::pointer;
107 return data_.begin();
115 return data_.cbegin();
127 data_.resize(new_size);
131 data_.reserve(new_size);
135 return data_.empty();
145 VectorElement&
at(
size_t i)
149 const VectorElement&
at(
size_t i)
const
157 const VectorElement&
back() const noexcept
167 data_.push_back(std::move(f));
169 template<
typename...
Args>
172 return data_.emplace_back(std::forward<Args>(args)...);
180 return data_.erase(where);
184 return data_.erase(from, to);
189 return data_.insert(where, from, to);
Definition: ExposedVector.h:55
iterator insert(const_iterator where, T from, T to)
Definition: ExposedVector.h:187
std::vector< VectorElement > VecMember
Definition: ExposedVector.h:57
typename VecMember::iterator iterator
Definition: ExposedVector.h:61
const_iterator begin() const noexcept
Definition: ExposedVector.h:105
typename VecMember::const_iterator const_iterator
Definition: ExposedVector.h:62
void reserve(const size_t new_size)
Definition: ExposedVector.h:129
typename VecMember::pointer pointer
Definition: ExposedVector.h:66
size_t size() const noexcept
Definition: ExposedVector.h:121
bool empty() const noexcept
Definition: ExposedVector.h:133
ExposedVector(const size_t n)
Definition: ExposedVector.h:76
decltype(auto) emplace_back(Args &&... args)
Definition: ExposedVector.h:170
typename VecMember::size_type size_type
Definition: ExposedVector.h:65
VectorElement & back() noexcept
Definition: ExposedVector.h:153
typename VecMember::value_type value_type
Definition: ExposedVector.h:60
const_iterator end() const noexcept
Definition: ExposedVector.h:109
typename VecMember::reverse_iterator reverse_iterator
Definition: ExposedVector.h:63
typename VecMember::const_reference const_reference
Definition: ExposedVector.h:68
ExposedVector(ExposedVector &&rhs) noexcept=default
Move C'tor.
const VectorElement & back() const noexcept
Definition: ExposedVector.h:157
typename VecMember::difference_type difference_type
Definition: ExposedVector.h:69
VecMember data_
the container which holds all the data
Definition: ExposedVector.h:72
ExposedVector & operator=(ExposedVector &&rhs) noexcept=default
Move Assignment.
const VectorElement & operator[](size_t i) const noexcept
Definition: ExposedVector.h:141
void pop_back() noexcept
Definition: ExposedVector.h:174
iterator begin() noexcept
Definition: ExposedVector.h:97
const_iterator cend() const noexcept
Definition: ExposedVector.h:117
void resize(const size_t new_size)
Definition: ExposedVector.h:125
void push_back(VectorElement &&f)
Definition: ExposedVector.h:165
ExposedVector & operator=(const ExposedVector &rhs)=default
Assignment.
VectorElement & at(size_t i)
Definition: ExposedVector.h:145
typename VecMember::reference reference
Definition: ExposedVector.h:67
VectorElement & operator[](size_t i) noexcept
Definition: ExposedVector.h:137
const VectorElement & at(size_t i) const
Definition: ExposedVector.h:149
ExposedVector(const size_t n, const VectorElement &val)
Definition: ExposedVector.h:80
const_iterator cbegin() const noexcept
Definition: ExposedVector.h:113
void push_back(const VectorElement &f)
Definition: ExposedVector.h:161
VecMember & getData()
read access to the underlying data
Definition: ExposedVector.h:198
ExposedVector(const ExposedVector &rhs)=default
Copy C'tor.
ExposedVector(Iter begin, Iter end)
Definition: ExposedVector.h:83
typename VecMember::const_reverse_iterator const_reverse_iterator
Definition: ExposedVector.h:64
const VecMember & getData() const
read-only access to the underlying data
Definition: ExposedVector.h:193
iterator erase(const_iterator where) noexcept
Definition: ExposedVector.h:178
iterator erase(const_iterator from, const_iterator to) noexcept
Definition: ExposedVector.h:182
iterator end() noexcept
Definition: ExposedVector.h:101
custom arguments to allow for looping calls
Definition: WizardHelper.h:47
Main OpenMS namespace.
Definition: openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19