QConstIterator Struct | Qt Core (original) (raw)

Member Function Documentation

[explicit] QConstIterator::QConstIterator(const QIterable<Container> *iterable, void *iterator)

Creates a QConstIterator to wrap iterator, operating on iterable.

bool QConstIterator::operator!=(const QConstIterator<Container> &other) const

Returns true if other points to a different item than this iterator; otherwise returns false.

See also operator==().

QConstIterator<Container> QConstIterator::operator+(qsizetype j) const

Returns an iterator to the item at j positions forward from this iterator.

See also operator-() and operator+=().

QConstIterator<Container> &QConstIterator::operator++()

The prefix ++ operator (++it) advances the iterator to the next item in the container and returns an iterator to the new current item.

Calling this function on QIterable::end() leads to undefined results.

See also operator--().

QConstIterator<Container> QConstIterator::operator++(int)

This is an overloaded function.

The postfix ++ operator (it++) advances the iterator to the next item in the container and returns an iterator to the previously current item.

QConstIterator<Container> &QConstIterator::operator+=(qsizetype j)

Advances the iterator by j items.

See also operator-=() and operator+().

QConstIterator<Container> QConstIterator::operator-(qsizetype j) const

Returns an iterator to the item at j positions backward from this iterator.

If the container in the QVariant does not support bi-directional iteration, calling this function leads to undefined results.

See also operator+(), operator-=(), and QIterable::canReverseIterate().

qsizetype QConstIterator::operator-(const QConstIterator<Container> &j) const

This is an overloaded function.

Returns the distance between the two iterators.

See also operator+(), operator-=(), and QIterable::canReverseIterate().

QConstIterator<Container> &QConstIterator::operator--()

The prefix -- operator (--it) makes the preceding item current and returns an iterator to the new current item.

Calling this function on QIterable::begin() leads to undefined results.

If the container in the QVariant does not support bi-directional iteration, calling this function leads to undefined results.

See also operator++() and QIterable::canReverseIterate().

QConstIterator<Container> QConstIterator::operator--(int)

This is an overloaded function.

The postfix -- operator (it--) makes the preceding item current and returns an iterator to the previously current item.

If the container in the QVariant does not support bi-directional iteration, calling this function leads to undefined results.

See also QIterable::canReverseIterate().

QConstIterator<Container> &QConstIterator::operator-=(qsizetype j)

Makes the iterator go back by j items.

If the container in the QVariant does not support bi-directional iteration, calling this function leads to undefined results.

See also operator+=(), operator-(), and QIterable::canReverseIterate().

bool QConstIterator::operator==(const QConstIterator<Container> &other) const

Returns true if other points to the same item as this iterator; otherwise returns false.

See also operator!=().