ITK  5.2.0
Insight Toolkit
Public Types | Public Member Functions | Private Types | Private Member Functions | Private Attributes | Friends | List of all members
itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst > Class Template Referencefinal
+ Collaboration diagram for itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >:

Public Types

using difference_type = std::ptrdiff_t
 
using iterator_category = std::bidirectional_iterator_tag
 
using pointer = typename std::iterator_traits< QualifiedBufferIteratorType >::pointer
 
using reference = typename std::iterator_traits< QualifiedBufferIteratorType >::reference
 
using value_type = typename std::iterator_traits< QualifiedBufferIteratorType >::value_type
 

Public Member Functions

reference operator* () const noexcept
 
 QualifiedIterator ()=default
 
 QualifiedIterator (const QualifiedIterator< false > &arg) noexcept
 

Private Types

using QualifiedBufferIteratorType = typename std::conditional< VIsConst, typename ImageBufferRange< TImage >::const_iterator, typename ImageBufferRange< TImage >::iterator >::type
 

Private Member Functions

template<std::vcl_size_t VIndex>
void Decrement (std::false_type) noexcept
 
template<std::vcl_size_t VIndex>
void Decrement (std::true_type) noexcept
 
template<std::vcl_size_t VIndex>
void Increment (std::false_type) noexcept
 
template<std::vcl_size_t VIndex>
void Increment (std::true_type) noexcept
 
 QualifiedIterator (const QualifiedBufferIteratorType &bufferIterator, const OffsetTableType &offsetTable, const OffsetType &iterationOffset, const SizeType &regionSize) noexcept
 

Private Attributes

QualifiedBufferIteratorType m_BufferIterator {}
 
OffsetType m_IterationOffset { {} }
 
SizeType m_IterationRegionSize { {} }
 
OffsetTableType m_OffsetTable { {} }
 

Friends

class ImageRegionRange
 
class QualifiedIterator<!VIsConst >
 
bool operator== (const QualifiedIterator &lhs, const QualifiedIterator &rhs) noexcept
 
bool operator!= (const QualifiedIterator &lhs, const QualifiedIterator &rhs) noexcept
 
QualifiedIteratoroperator++ () noexcept
 
QualifiedIterator operator++ (int) noexcept
 
QualifiedIteratoroperator-- () noexcept
 
QualifiedIterator operator-- (int) noexcept
 
QualifiedIteratoroperator= (const QualifiedIterator &) noexcept=default
 
 ~QualifiedIterator ()=default
 

Detailed Description

template<typename TImage>
template<bool VIsConst>
class itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >

Iterator class that is either 'const' or non-const qualified. A non-const qualified instantiation of this template allows the pixel that it points to, to be modified. A const qualified instantiation does not.

Note
The definition of this class is private. Please use its type alias ImageRegionRange::iterator, or ImageRegionRange::const_iterator!
See also
ImageRegionRange

Definition at line 103 of file itkImageRegionRange.h.

Member Typedef Documentation

◆ difference_type

template<typename TImage >
template<bool VIsConst>
using itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::difference_type = std::ptrdiff_t

Definition at line 200 of file itkImageRegionRange.h.

◆ iterator_category

template<typename TImage >
template<bool VIsConst>
using itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::iterator_category = std::bidirectional_iterator_tag

Definition at line 204 of file itkImageRegionRange.h.

◆ pointer

template<typename TImage >
template<bool VIsConst>
using itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::pointer = typename std::iterator_traits<QualifiedBufferIteratorType>::pointer

Definition at line 203 of file itkImageRegionRange.h.

◆ QualifiedBufferIteratorType

template<typename TImage >
template<bool VIsConst>
using itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::QualifiedBufferIteratorType = typename std::conditional<VIsConst, typename ImageBufferRange<TImage>::const_iterator, typename ImageBufferRange<TImage>::iterator>::type
private

Definition at line 117 of file itkImageRegionRange.h.

◆ reference

template<typename TImage >
template<bool VIsConst>
using itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::reference = typename std::iterator_traits<QualifiedBufferIteratorType>::reference

Definition at line 202 of file itkImageRegionRange.h.

◆ value_type

template<typename TImage >
template<bool VIsConst>
using itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::value_type = typename std::iterator_traits<QualifiedBufferIteratorType>::value_type

Definition at line 201 of file itkImageRegionRange.h.

Constructor & Destructor Documentation

◆ QualifiedIterator() [1/3]

template<typename TImage >
template<bool VIsConst>
itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::QualifiedIterator ( const QualifiedBufferIteratorType bufferIterator,
const OffsetTableType offsetTable,
const OffsetType iterationOffset,
const SizeType regionSize 
)
inlineprivatenoexcept

Definition at line 135 of file itkImageRegionRange.h.

◆ QualifiedIterator() [2/3]

template<typename TImage >
template<bool VIsConst>
itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::QualifiedIterator ( )
default

Default-constructor, as required for any C++11 Forward Iterator. Offers the guarantee added to the C++14 Standard: "value-initialized iterators may be compared and shall compare equal to other value-initialized iterators of the same type."

◆ QualifiedIterator() [3/3]

template<typename TImage >
template<bool VIsConst>
itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::QualifiedIterator ( const QualifiedIterator< false > &  arg)
inlinenoexcept

Constructor that allows implicit conversion from non-const to const iterator. Also serves as copy-constructor of a non-const iterator.

Definition at line 215 of file itkImageRegionRange.h.

◆ ~QualifiedIterator()

template<typename TImage >
template<bool VIsConst>
itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::~QualifiedIterator ( )
default

Explicitly-defaulted destructor.

Member Function Documentation

◆ Decrement() [1/2]

template<typename TImage >
template<bool VIsConst>
template<std::vcl_size_t VIndex>
void itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::Decrement ( std::false_type  )
inlineprivatenoexcept

◆ Decrement() [2/2]

template<typename TImage >
template<bool VIsConst>
template<std::vcl_size_t VIndex>
void itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::Decrement ( std::true_type  )
inlineprivatenoexcept

◆ Increment() [1/2]

template<typename TImage >
template<bool VIsConst>
template<std::vcl_size_t VIndex>
void itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::Increment ( std::false_type  )
inlineprivatenoexcept

◆ Increment() [2/2]

template<typename TImage >
template<bool VIsConst>
template<std::vcl_size_t VIndex>
void itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::Increment ( std::true_type  )
inlineprivatenoexcept

◆ operator*()

template<typename TImage >
template<bool VIsConst>
reference itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::operator* ( ) const
inlinenoexcept

Returns a reference to the current pixel.

Definition at line 227 of file itkImageRegionRange.h.

References itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::m_BufferIterator.

◆ operator++() [1/2]

template<typename TImage >
template<bool VIsConst>
QualifiedIterator& itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::operator++ ( )
inlinenoexcept

Prefix increment ('++it').

Definition at line 231 of file itkImageRegionRange.h.

References itk::ImageRegionRange< TImage >::ImageDimension.

◆ operator++() [2/2]

template<typename TImage >
template<bool VIsConst>
QualifiedIterator itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::operator++ ( int  )
inlinenoexcept

Postfix increment ('it++').

Note
Usually prefix increment ('++it') is preferable.

Definition at line 242 of file itkImageRegionRange.h.

◆ operator--() [1/2]

template<typename TImage >
template<bool VIsConst>
QualifiedIterator& itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::operator-- ( )
inlinenoexcept

Prefix decrement ('–it').

Definition at line 253 of file itkImageRegionRange.h.

References itk::ImageRegionRange< TImage >::ImageDimension.

◆ operator--() [2/2]

template<typename TImage >
template<bool VIsConst>
QualifiedIterator itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::operator-- ( int  )
inlinenoexcept

Postfix increment ('it–').

Note
Usually prefix increment ('–it') is preferable.

Definition at line 264 of file itkImageRegionRange.h.

◆ operator=()

template<typename TImage >
template<bool VIsConst>
QualifiedIterator& itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::operator= ( const QualifiedIterator< VIsConst > &  )
defaultnoexcept

Explicitly-defaulted assignment operator.

Friends And Related Function Documentation

◆ ImageRegionRange

template<typename TImage >
template<bool VIsConst>
friend class ImageRegionRange
friend

Definition at line 112 of file itkImageRegionRange.h.

◆ operator!=

template<typename TImage >
template<bool VIsConst>
bool operator!= ( const QualifiedIterator< VIsConst > &  lhs,
const QualifiedIterator< VIsConst > &  rhs 
)
friend

Returns (it1 != it2) for iterators it1 and it2.

Definition at line 285 of file itkImageRegionRange.h.

◆ operator==

template<typename TImage >
template<bool VIsConst>
bool operator== ( const QualifiedIterator< VIsConst > &  lhs,
const QualifiedIterator< VIsConst > &  rhs 
)
friend

Returns (it1 == it2) for iterators it1 and it2. Note that these iterators should be from the same range. This operator does not support comparing iterators from different ranges.

Definition at line 277 of file itkImageRegionRange.h.

◆ QualifiedIterator<!VIsConst >

template<typename TImage >
template<bool VIsConst>
friend class QualifiedIterator<!VIsConst >
friend

Definition at line 108 of file itkImageRegionRange.h.

Member Data Documentation

◆ m_BufferIterator

template<typename TImage >
template<bool VIsConst>
QualifiedBufferIteratorType itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::m_BufferIterator {}
private

◆ m_IterationOffset

template<typename TImage >
template<bool VIsConst>
OffsetType itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::m_IterationOffset { {} }
private

◆ m_IterationRegionSize

template<typename TImage >
template<bool VIsConst>
SizeType itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::m_IterationRegionSize { {} }
private

◆ m_OffsetTable

template<typename TImage >
template<bool VIsConst>
OffsetTableType itk::ImageRegionRange< TImage >::QualifiedIterator< VIsConst >::m_OffsetTable { {} }
private

The documentation for this class was generated from the following file: