16#ifndef dealii_hp_collection_h
17#define dealii_hp_collection_h
46 const std::size_t
index)
71 "You are trying to compare iterators into different hp::Collection objects."));
84 "You are trying to compare iterators into different hp::Collection objects."));
95 return *(*data)[
index];
134 "You can't decrement an iterator that is already at the beginning of the range."));
155 return static_cast<std::ptrdiff_t
>(
index) -
156 static_cast<ptrdiff_t
>(other.
index);
163 const std::vector<std::shared_ptr<const T>> *
data;
180 template <
typename T>
237 std::vector<std::shared_ptr<const T>>
entries;
245 template <
typename T>
254 template <
typename T>
258 entries.push_back(new_entry);
263 template <
typename T>
267 return entries.size();
272 template <
typename T>
277 return *entries[index];
282 template <
typename T>
291 template <
typename T>
311 typename std::vector<std::shared_ptr<const T>>::iterator>
std::ptrdiff_t operator-(const CollectionIterator< T > &other) const
CollectionIterator< T > operator+(const std::size_t &offset) const
const T & operator*() const
CollectionIterator< T > & operator++()
CollectionIterator< T > & operator+=(const std::size_t offset)
CollectionIterator(const std::vector< std::shared_ptr< const T > > &data, const std::size_t index)
CollectionIterator(const CollectionIterator< T > &other)=default
CollectionIterator< T > & operator=(const CollectionIterator< T > &other)=default
bool operator==(const CollectionIterator< T > &other) const
bool operator!=(const CollectionIterator< T > &other) const
CollectionIterator< T > & operator--()
const std::vector< std::shared_ptr< const T > > * data
void push_back(const std::shared_ptr< const T > &new_entry)
std::vector< std::shared_ptr< const T > > entries
CollectionIterator< T > begin() const
unsigned int size() const
std::size_t memory_consumption() const
CollectionIterator< T > end() const
const T & operator[](const unsigned int index) const
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
#define Assert(cond, exc)
#define AssertIndexRange(index, range)
static ::ExceptionBase & ExcMessage(std::string arg1)
std::enable_if_t< std::is_fundamental< T >::value, std::size_t > memory_consumption(const T &t)