32#ifndef _QX_COLLECTION_ITERATOR_H_
33#define _QX_COLLECTION_ITERATOR_H_
65template <
typename Key,
typename Value>
79 inline const Key &
key()
const;
80 inline const Value &
value()
const;
97#include "../../inl/QxCollection/QxCollectionIterator.inl"
QxOrm thread-safe container (keep insertion order + quick access by index + quick access by key)
qx::QxCollection<Key, Value> : QxOrm thread-safe container (keep insertion order + quick access by in...
qx::QxCollectionIterator : Java-style iterator to iterate over a qx::QxCollection<Key,...
void toFirst()
Move the iterator to the front of the container (before the first item)
QxCollectionIterator(const QxCollection< Key, Value > &col)
Construct an iterator for traversing the collection. The iterator is set to be at the front of the li...
const Key & key() const
Return the 'key' at current position.
QxCollectionIterator & operator=(const QxCollectionIterator &other)
const Value & value() const
Return the 'value' at current position.
bool previous()
Move the iterator back by one position. Return 'true' if there is at least one item behind the iterat...
const QxCollection< Key, Value > * m_pCollection
Collection to iterate over.
QxCollectionIterator(const QxCollectionIterator &other)
void toLast()
Move the iterator to the back of the container (after the last item)
long m_lCurrIndex
Current index (position) in the collection.
bool next()
Advance the iterator by one position. Return 'true' if there is at least one item ahead of the iterat...
~QxCollectionIterator()
Destroy the iterator.
Root namespace for all QxOrm library features.