dip::PixelTable::iterator class

An iterator that visits each of the neighborhood’s pixels in turn.

Dereferencing the iterator returns the coordinates of the pixel. Satisfies the requirements for ForwardIterator.

Constructors, destructors, assignment and conversion operators

iterator() defaulted
Default constructor yields an invalid iterator that cannot be dereferenced.
iterator(dip::PixelTable const& pt) explicit
Constructs an iterator to the first pixel in the neighborhood.

Aliases

using iterator_category = std::forward_iterator_tag
Iterator category.
using reference = dip::IntegerArray const&
The type of a reference.
using value_type = dip::IntegerArray
The value obtained by dereferencing are coordinates.

Functions

static auto end(dip::PixelTable const& pt) -> dip::PixelTable::iterator
Constructs an end iterator.
auto IsAtEnd() const -> bool
Test to see if the iterator reached past the last pixel.
void swap(dip::PixelTable::iterator& other) noexcept
Swap.

Operators

auto operator bool() const -> bool explicit
Test to see if the iterator is still pointing at a pixel.
auto operator!=(dip::PixelTable::iterator const& other) const -> bool
Inequality comparison.
auto operator*() const -> dip::PixelTable::iterator::reference
Dereference.
auto operator++() -> dip::PixelTable::iterator&
Pre-increment.
auto operator++(int ) -> dip::PixelTable::iterator
Post-increment.
auto operator==(dip::PixelTable::iterator const& other) const -> bool
Equality comparison, is true if the two iterators reference the same pixel in the same pixel table.

Alias documentation

using iterator_category = std::forward_iterator_tag

Iterator category.

using value_type = dip::IntegerArray

The value obtained by dereferencing are coordinates.

using reference = dip::IntegerArray const&

The type of a reference.

Function documentation

iterator( ) defaulted

Default constructor yields an invalid iterator that cannot be dereferenced.

iterator( dip::PixelTable const& pt) explicit

Constructs an iterator to the first pixel in the neighborhood.

static dip::PixelTable::iterator end( dip::PixelTable const& pt)

Constructs an end iterator.

void swap( dip::PixelTable::iterator& other) noexcept

Swap.

bool IsAtEnd( ) const

Test to see if the iterator reached past the last pixel.

dip::PixelTable::iterator operator++( int )

Post-increment.

bool operator==( dip::PixelTable::iterator const& other) const

Equality comparison, is true if the two iterators reference the same pixel in the same pixel table.

bool operator!=( dip::PixelTable::iterator const& other) const

Inequality comparison.

bool operator bool( ) const explicit

Test to see if the iterator is still pointing at a pixel.