Boost logo

Boost :

From: Matt Verona (mattverona_at_[hidden])
Date: 2001-10-30 05:10:16


We're in need of a "subvector iterator" class, that locates sequences of
records contained within a (sorted) source vector.

For example, the source vector is sorted, such that records with matching
ids are stored together, in contiguous groups. The subvector iterator would
then be used to locate each set of consecutive records.

The subvector iterator's ++ operator would advance two internal pointers, to
mark the next set of matching records (beginning and one past the end
iterators), and the iterator's dereference operator * would return the
current subvector (i.e., a vector<Record> or possibly an STL pair of
bounding iterators).

Before we implement this custom iterator, I wanted to see if Boost has
anything like it. BTW, I have seen string token iterators that have similar
functionality, but this one needs to return subvectors (or a pair of
iterators), not substrings...


-Matt Verona
Houston Texas

Boost list run by bdawes at, gregod at, cpdaniel at, john at