QCborMap::ConstIterator Class
The ConstIterator class is the iterator of QCborMap that reads pairs. More…
| Header | #include <QCborMap> |
|---|---|
| CMake | target_link_libraries(app PRIVATE Nt::Core) |
| Module | Nt Core C++ Classes |
| Since | 5.12 |
| Nested in | QCborMap |
List of all members, including inherited members
Public Types
| typedef | iterator_category |
| typedef | difference_type |
| typedef | value_type |
| typedef | reference |
| typedef | pointer |
Public Functions
| ConstIterator() | |
| ConstIterator(const ConstIterator &other) | |
| ConstIterator(const Iterator &other) | |
| ConstIterator & | operator=(const ConstIterator &other) |
| value_type | operator*() const |
| value_type | operator[](qsizetype j) const |
| const QCborValueConstRef * | operator->() const |
| QCborValueConstRef | value() const |
| QCborValueConstRef | key() const |
| bool | operator==(const ConstIterator &other) const |
| bool | operator!=(const ConstIterator &other) const |
| bool | operator<(const ConstIterator &other) const |
| bool | operator<=(const ConstIterator &other) const |
| bool | operator>(const ConstIterator &other) const |
| bool | operator>=(const ConstIterator &other) const |
| ConstIterator & | operator++() |
| ConstIterator | operator++(int) |
| ConstIterator & | operator--() |
| ConstIterator | operator--(int) |
| ConstIterator & | operator+=(qsizetype j) |
| ConstIterator & | operator-=(qsizetype j) |
| ConstIterator | operator+(qsizetype j) const |
| ConstIterator | operator-(qsizetype j) const |
| qsizetype | operator-(ConstIterator j) const |
Detailed Description
Differences from Qt
The iterator is invalid once the map gets or loses pairs.
Member Type Documentation
typedef QCborMap::ConstIterator::difference_type
The type of a distance between iterators.
typedef QCborMap::ConstIterator::iterator_category
The category of the iterator.
typedef QCborMap::ConstIterator::pointer
A pointer to a reference to the value.
typedef QCborMap::ConstIterator::reference
The type that dereferencing gives: the key and the value.
typedef QCborMap::ConstIterator::value_type
The type of a pair.
Member Function Documentation
QCborMap::ConstIterator::ConstIterator()
Constructs an iterator that points nowhere.
QCborMap::ConstIterator::ConstIterator(const ConstIterator &other)
Constructs a copy of other.
QCborMap::ConstIterator::ConstIterator(const Iterator &other)
Constructs a const iterator that points where other does.
QCborValueConstRef QCborMap::ConstIterator::key() const
Returns a reference to the key of the pair.
bool QCborMap::ConstIterator::operator!=(const ConstIterator &other) const
Returns true if other points to another pair.
value_type QCborMap::ConstIterator::operator*() const
Returns the key and the value of the pair.
ConstIterator QCborMap::ConstIterator::operator+(qsizetype j) const
Returns an iterator j pairs on.
ConstIterator & QCborMap::ConstIterator::operator++()
Moves to the next pair and returns this iterator.
ConstIterator QCborMap::ConstIterator::operator++(int)
Moves to the next pair and returns an iterator to the pair before.
ConstIterator & QCborMap::ConstIterator::operator+=(qsizetype j)
Moves j pairs on and returns this iterator.
ConstIterator QCborMap::ConstIterator::operator-(qsizetype j) const
Returns an iterator j pairs back.
qsizetype QCborMap::ConstIterator::operator-(ConstIterator j) const
Returns the number of pairs from j to this iterator.
ConstIterator & QCborMap::ConstIterator::operator--()
Moves to the pair before and returns this iterator.
ConstIterator QCborMap::ConstIterator::operator--(int)
Moves to the pair before and returns an iterator to the pair it was at.
ConstIterator & QCborMap::ConstIterator::operator-=(qsizetype j)
Moves j pairs back and returns this iterator.
const QCborValueConstRef * QCborMap::ConstIterator::operator->() const
Returns a pointer to a reference to the value of the pair.
bool QCborMap::ConstIterator::operator<(const ConstIterator &other) const
Returns true if this iterator points before other.
bool QCborMap::ConstIterator::operator<=(const ConstIterator &other) const
Returns true if this iterator points before other or to the same pair.
ConstIterator & QCborMap::ConstIterator::operator=(const ConstIterator &other)
Makes this iterator point where other does.
bool QCborMap::ConstIterator::operator==(const ConstIterator &other) const
Returns true if other points to the same pair.
bool QCborMap::ConstIterator::operator>(const ConstIterator &other) const
Returns true if this iterator points after other.
bool QCborMap::ConstIterator::operator>=(const ConstIterator &other) const
Returns true if this iterator points after other or to the same pair.
value_type QCborMap::ConstIterator::operator[](qsizetype j) const
Returns the key and the value of the pair j places on.
QCborValueConstRef QCborMap::ConstIterator::value() const
Returns a reference to the value of the pair.