CopperSpice API
1.9.1
|
Provides an STL style const iterator for QSet. More...
Public Typedefs | |
using | iterator_category = std::forward_iterator_tag |
Public Methods | |
const_iterator () | |
const_iterator (const const_iterator &other) | |
const_iterator (const iterator &other) | |
const_iterator (const_iterator &&other) | |
const_iterator (iterator &&other) | |
const T & | operator* () const |
const_iterator | operator+ (size_type n) const |
const_iterator & | operator++ () |
const_iterator | operator++ (int) |
const_iterator & | operator+= (size_type n) |
const T * | operator-> () const |
const_iterator & | operator= (const const_iterator &other) |
const_iterator & | operator= (const iterator &other) |
const_iterator & | operator= (const_iterator &&other) |
const_iterator & | operator= (iterator &&other) |
bool | operator== (const_iterator other) const |
The QSet::const_iterator class provides an STL style const iterator for QSet.
QSet< T >::const_iterator::iterator_category |
Equivalent to std::forward_iterator_tag indicating this iterators is a forward iterator.
QSet< T >::const_iterator::const_iterator | ( | ) |
Constructs an uninitialized iterator.
Functions like operator*() and operator++() should not be called on an uninitialized iterator. Use operator=() to assign a value to it before using it.
QSet< T >::const_iterator::const_iterator | ( | const const_iterator & | other | ) |
Constructs a copy of other.
Copy constructs a new QSet::const_iterator from other.
QSet< T >::const_iterator::const_iterator | ( | const_iterator && | other | ) |
Move constructs a new QSet::const_iterator from other.
Move constructs a new QSet::const_iterator from other.
const T & QSet< T >::const_iterator::operator* | ( | ) | const |
Returns a reference to the current item.
const_iterator QSet< T >::const_iterator::operator+ | ( | size_type | n | ) | const |
Returns an iterator to the item at n positions forward from this iterator. If n is negative the iterator goes backward.
This operation can be slow for large values of n.
const_iterator & QSet< T >::const_iterator::operator++ | ( | ) |
The prefix ++ operator (++it
) advances the iterator to the next item in the set and returns an iterator to the new current item.
Calling this method on QSet::constEnd() leads to undefined behavior.
const_iterator QSet< T >::const_iterator::operator++ | ( | int | ) |
The postfix ++ operator (it++
) advances the iterator to the next item in the set and returns an iterator to the previously current item.
const_iterator & QSet< T >::const_iterator::operator+= | ( | size_type | n | ) |
Advances the iterator by n items. If n is negative the iterator goes backward.
This operation can be slow for large values of n.
const T * QSet< T >::const_iterator::operator-> | ( | ) | const |
Returns a pointer to the current item.
const_iterator & QSet< T >::const_iterator::operator= | ( | const const_iterator & | other | ) |
Copy assigns from other and returns a reference to this object.
const_iterator & QSet< T >::const_iterator::operator= | ( | const iterator & | other | ) |
Copy assigns from other and returns a reference to this object.
const_iterator & QSet< T >::const_iterator::operator= | ( | const_iterator && | other | ) |
Move assigns from other and returns a reference to this object.
const_iterator & QSet< T >::const_iterator::operator= | ( | iterator && | other | ) |
Move assigns from other and returns a reference to this object.
bool QSet< T >::const_iterator::operator== | ( | const_iterator | other | ) | const |
Returns true if other points to the same item as this iterator, otherwise returns false.