Note that the traversal order is arbitrary; you are not guaranteed any particular order. If new objects are inserted into the cache while the iterator is active, the iterator may or may not see them.
Multiple iterators are completely independent, even when they operate on the same TQCache. TQCache updates all iterators that refer an item when that item is removed.
TQCacheIterator provides an operator++(), and an operator+=() to traverse the cache. The current() and currentKey() functions are used to access the current cache item and its key. The atFirst() and atLast() return TRUE if the iterator points to the first or last item in the cache respectively. The isEmpty() function returns TRUE if the cache is empty, and count() returns the number of items in the cache.
Constructs an iterator for the same cache as \fIci\fR. The new iterator starts at the same item as ci.current(), but moves independently from there on.
Returns TRUE if the iterator points to the first item in the cache; otherwise returns FALSE. Note that this refers to the iterator's arbitrary ordering, not to the cache's internal least recently used list.
Returns TRUE if the iterator points to the last item in the cache; otherwise returns FALSE. Note that this refers to the iterator's arbitrary ordering, not to the cache's internal least recently used list.
Prefix++ makes the iterator point to the item just after current() and makes that the new current item for the iterator. If current() was the last item, operator++() returns 0.
Prefix-- makes the iterator point to the item just before current() and makes that the new current item for the iterator. If current() was the first item, operator--() returns 0.