|
ITK
5.1.0
Insight Toolkit
|
Go to the documentation of this file.
18 #ifndef itkMapContainer_h
19 #define itkMapContainer_h
44 template <
typename TElementIdentifier,
typename TElement>
47 ,
private std::map<TElementIdentifier, TElement>
67 using MapType = std::map<ElementIdentifier, Element>;
83 template <
typename TInputIterator>
87 template <
typename TInputIterator>
107 const STLContainerType &
113 using STLContainerType::begin;
114 using STLContainerType::end;
115 using STLContainerType::rbegin;
116 using STLContainerType::rend;
118 using STLContainerType::empty;
119 using STLContainerType::size;
120 using STLContainerType::max_size;
122 using STLContainerType::operator[];
124 using STLContainerType::insert;
125 using STLContainerType::erase;
127 using STLContainerType::clear;
129 using STLContainerType::key_comp;
130 using STLContainerType::value_comp;
132 using STLContainerType::find;
133 using STLContainerType::count;
134 using STLContainerType::lower_bound;
135 using STLContainerType::upper_bound;
136 using STLContainerType::equal_range;
138 using STLContainerType::get_allocator;
140 using typename STLContainerType::key_type;
141 using typename STLContainerType::mapped_type;
142 using typename STLContainerType::value_type;
143 using typename STLContainerType::key_compare;
144 using typename STLContainerType::value_compare;
145 using typename STLContainerType::allocator_type;
146 using typename STLContainerType::reference;
147 using typename STLContainerType::const_reference;
148 using typename STLContainerType::iterator;
149 using typename STLContainerType::const_iterator;
150 using typename STLContainerType::size_type;
151 using typename STLContainerType::difference_type;
152 using typename STLContainerType::pointer;
153 using typename STLContainerType::const_pointer;
154 using typename STLContainerType::reverse_iterator;
155 using typename STLContainerType::const_reverse_iterator;
173 using pointer =
typename MapIterator::pointer;
222 return m_Iter == r.
m_Iter;
227 return m_Iter != r.
m_Iter;
232 return m_Iter == r.
m_Iter;
237 return m_Iter != r.
m_Iter;
244 return m_Iter->first;
251 return m_Iter->second;
269 using pointer =
typename MapConstIterator::pointer;
318 return m_Iter == r.
m_Iter;
323 return m_Iter != r.
m_Iter;
328 return m_Iter == r.
m_Iter;
333 return m_Iter != r.
m_Iter;
340 return m_Iter->first;
347 return m_Iter->second;
481 #ifndef ITK_MANUAL_INSTANTIATION
482 # include "itkMapContainer.hxx"
ConstIterator & operator--()
ConstIterator(const MapConstIterator &ci)
bool operator==(const Iterator &r) const
bool operator!=(const Iterator &r) const
const STLContainerType & CastToSTLConstContainer() const noexcept
typename MapType::const_iterator MapConstIterator
Represent a n-dimensional size (bounds) of a n-dimensional image.
typename MapType::iterator MapIterator
ConstIterator & operator=(const ConstIterator &r)
ConstIterator & operator++()
std::map< ElementIdentifier, Element > MapType
ConstIterator operator++(int)
STLContainerType & CastToSTLContainer() noexcept
bool operator!=(const Iterator &r) const
void swap(Array< T > &a, Array< T > &b)
ConstIterator * operator->()
ConstIterator & operator*()
The non-const iterator type for the map.
The const iterator type for the map.
MapContainer(TInputIterator first, TInputIterator last)
typename MapConstIterator::iterator_category iterator_category
A wrapper of the STL "map" container.
Light weight base class for most itk classes.
bool operator!=(const ConstIterator &r) const
typename MapIterator::reference reference
typename MapType::key_compare MapKeyCompareType
ElementIdentifier Index() const
bool operator==(const ConstIterator &r) const
Iterator & operator=(const Iterator &r)
MapContainer(const MapKeyCompareType &comp)
const Element & Value() const
typename MapIterator::difference_type difference_type
Iterator(const Iterator &i)
bool operator==(const ConstIterator &r) const
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
typename MapIterator::value_type value_type
typename MapConstIterator::pointer pointer
typename MapIterator::pointer pointer
ElementIdentifier Index() const
Base class for most ITK classes.
MapContainer(TInputIterator first, TInputIterator last, const MapKeyCompareType &comp)
typename MapConstIterator::value_type value_type
ConstIterator operator--(int)
typename MapConstIterator::difference_type difference_type
bool operator!=(const ConstIterator &r) const
Iterator(const MapIterator &i)
typename MapIterator::iterator_category iterator_category
ConstIterator(const Iterator &r)
TElementIdentifier ElementIdentifier
typename MapConstIterator::reference reference
bool operator==(const Iterator &r) const