Classes - Annotated - Tree - Functions - Home - Structure

QMapConstIterator Class Reference

The QMapConstIterator class provides an iterator for QMap. More...

#include <qmap.h>

List of all member functions.

Public Members


Detailed Description

The QMapConstIterator class provides an iterator for QMap.

In contrast to QMapIterator, this class is used to iterate over a const map. It does not allow to modify the values of the map because this would break the const semantics.

For more informations on QMap iterators, see QMapIterator.

See also QMap and QMapIterator.


Member Type Documentation

QMapConstIterator::iterator_category

The type of iterator category, std::bidirectional_iterator_tag.

QMapConstIterator::pointer

Const pointer to value_type.

QMapConstIterator::reference

Const reference to value_type.

QMapConstIterator::value_type

The type of const value.

Member Function Documentation

QMapConstIterator::QMapConstIterator ()

Constructs an uninitialized iterator.

QMapConstIterator::QMapConstIterator ( QMapNode<K, T> * p )

Constructs an iterator starting at node p.

QMapConstIterator::QMapConstIterator ( const QMapConstIterator<K, T> & it )

Constructs a copy of the iterator.

QMapConstIterator::QMapConstIterator ( const QMapIterator<K, T> & it )

Constructs a copy of the iterator.

const T & QMapConstIterator::data () const

Returns a const reference to the data of the current item.

const K & QMapConstIterator::key () const

Returns a const reference to the current key.

bool QMapConstIterator::operator!= ( const QMapConstIterator<K, T> & it ) const

Compares both iterators and returns TRUE if they point to different items.

const T & QMapConstIterator::operator* () const

Asterix operator. Returns a const reference to the current item. The same as data().

QMapConstIterator<K, T> & QMapConstIterator::operator++ ()

Prefix ++ makes the succeeding item current and returns an iterator pointing to the new current item. The iterator can not check whether it reached the end of the map. Incrementing the iterator as returned by end() causes undefined results.

QMapConstIterator<K, T> QMapConstIterator::operator++ ( int )

Postfix ++ makes the succeeding item current and returns an iterator pointing to the new current item. The iterator can not check whether it reached the end of the map. Incrementing the iterator as returned by end() causes undefined results.

QMapConstIterator<K, T> & QMapConstIterator::operator-- ()

Prefix -- makes the previous item current and returns an iterator pointing to the new current item. The iterator can not check whether it reached the beginning of the map. Decrementing the iterator as returned by begin() causes undefined results.

QMapConstIterator<K, T> QMapConstIterator::operator-- ( int )

Postfix -- makes the previous item current and returns an iterator pointing to the new current item. The iterator can not check whether it reached the beginning of the map. Decrementing the iterator as returned by begin() causes undefined results.

bool QMapConstIterator::operator== ( const QMapConstIterator<K, T> & it ) const

Compares both iterators and returns TRUE if they point to the same item.


Search the documentation, FAQ, qt-interest archive and more (uses www.trolltech.com):


This file is part of the Qt toolkit, copyright © 1995-2001 Trolltech, all rights reserved.


Copyright © 2001 TrolltechTrademarks
Qt version 3.0.0-beta1-beta1