16 #error no need to expose this header to Swig
20 #ifndef BORNAGAIN_BASE_TYPES_SAFEPOINTERVECTOR_H
21 #define BORNAGAIN_BASE_TYPES_SAFEPOINTERVECTOR_H
33 typedef typename std::vector<T*>::iterator
iterator;
63 m_pointers.push_back((*it)->clone());
68 : m_pointers(
std::move(other.m_pointers))
79 m_pointers.push_back((*it)->clone());
87 m_pointers = std::move(right.m_pointers);
88 right.m_pointers.clear();
94 for (
iterator it = begin(); it != end(); ++it)
A vector of pointers, owned by *this, with methods to handle them safely.
const T * operator[](size_t index) const
const_iterator begin() const
SafePointerVector(const SafePointerVector &other)
SafePointerVector & operator=(const SafePointerVector &right)
const_iterator end() const
std::vector< T * >::const_iterator const_iterator
void push_back(T *pointer)
std::vector< T * > m_pointers
T * operator[](size_t index)
SafePointerVector(SafePointerVector &&other)
std::vector< T * >::iterator iterator
SafePointerVector & operator=(SafePointerVector &&right)