2006-09-11 22:27:29 +00:00
|
|
|
.. Distributed under the Boost
|
|
|
|
.. Software License, Version 1.0. (See accompanying
|
|
|
|
.. file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
|
|
|
|
2003-08-05 19:42:37 +00:00
|
|
|
+++++++++++++++++++
|
|
|
|
Counting Iterator
|
|
|
|
+++++++++++++++++++
|
|
|
|
|
|
|
|
:Author: David Abrahams, Jeremy Siek, Thomas Witt
|
|
|
|
:Contact: dave@boost-consulting.com, jsiek@osl.iu.edu, witt@ive.uni-hannover.de
|
|
|
|
:organization: `Boost Consulting`_, Indiana University `Open Systems
|
|
|
|
Lab`_, University of Hanover `Institute for Transport
|
|
|
|
Railway Operation and Construction`_
|
|
|
|
:date: $Date$
|
2004-11-01 21:23:47 +00:00
|
|
|
:copyright: Copyright David Abrahams, Jeremy Siek, and Thomas Witt 2003.
|
2003-08-05 19:42:37 +00:00
|
|
|
|
|
|
|
.. _`Boost Consulting`: http://www.boost-consulting.com
|
|
|
|
.. _`Open Systems Lab`: http://www.osl.iu.edu
|
|
|
|
.. _`Institute for Transport Railway Operation and Construction`: http://www.ive.uni-hannover.de
|
|
|
|
|
2004-01-12 20:58:22 +00:00
|
|
|
:abstract: How would you fill up a vector with the numbers zero
|
|
|
|
through one hundred using ``std::copy()``? The only iterator
|
|
|
|
operation missing from builtin integer types is an
|
|
|
|
``operator*()`` that returns the current value of the integer.
|
|
|
|
The counting iterator adaptor adds this crucial piece of
|
|
|
|
functionality to whatever type it wraps. One can use the
|
|
|
|
counting iterator adaptor not only with integer types, but with
|
2004-01-13 12:54:41 +00:00
|
|
|
any incrementable type.
|
2003-08-05 19:42:37 +00:00
|
|
|
|
2004-01-13 12:54:41 +00:00
|
|
|
.. include:: counting_iterator_abstract.rst
|
2003-08-05 19:42:37 +00:00
|
|
|
|
|
|
|
.. contents:: Table of Contents
|
|
|
|
|
2004-01-12 15:53:04 +00:00
|
|
|
``counting_iterator`` synopsis
|
|
|
|
..............................
|
|
|
|
|
2003-08-05 19:42:37 +00:00
|
|
|
.. include:: counting_iterator_ref.rst
|
2004-01-12 00:48:21 +00:00
|
|
|
.. include:: make_counting_iterator.rst
|
|
|
|
|
|
|
|
.. include:: counting_iterator_eg.rst
|
2004-01-15 00:01:33 +00:00
|
|
|
|
|
|
|
.. _iterator-category: iterator_facade.html#iterator-category
|
|
|
|
.. |iterator-category| replace:: *iterator-category*
|