bn::ilist::const_iterator class
#include <bn_list.h>

Const iterator.

Public types

using value_type = ilist::value_type
Value type alias.
using size_type = ilist::size_type
Size type alias.
using difference_type = ilist::difference_type
Difference type alias.
using reference = ilist::const_reference
Reference type alias.
using pointer = ilist::const_pointer
Pointer alias.
using iterator_category = bidirectional_iterator_tag
Iterator category alias.

Constructors, destructors, conversion operators

const_iterator() defaulted
Default constructor.
const_iterator(iterator it)
Constructor.

Public functions

auto operator++() -> const_iterator&
Increments the position.
auto operator++(int) -> const_iterator
Increments the position.
auto operator--() -> const_iterator&
Decrements the position.
auto operator--(int) -> const_iterator
Decrements the position.
auto operator*() const -> const_reference
Returns a const reference to the pointed value.
auto operator->() const -> const_pointer
Returns a const pointer to the pointed value.

Friends

auto operator==(const const_iterator& a, const const_iterator& b) -> bool defaulted
Default equal operator.

Function documentation

bn::ilist::const_iterator::const_iterator(iterator it)

Constructor.

Parameters
it Non const iterator.

const_iterator& bn::ilist::const_iterator::operator++()

Increments the position.

Returns Reference to this.

const_iterator bn::ilist::const_iterator::operator++(int)

Increments the position.

Returns The iterator before being incremented.

const_iterator& bn::ilist::const_iterator::operator--()

Decrements the position.

Returns Reference to this.

const_iterator bn::ilist::const_iterator::operator--(int)

Decrements the position.

Returns The iterator before being decremented.