Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of boost. Click here for the latest Boost documentation.
PrevUpHomeNext

Function template make_zip_iterator

boost::compute::make_zip_iterator

Synopsis

// In header: <boost/compute/iterator/zip_iterator.hpp>


template<typename IteratorTuple> 
  zip_iterator< IteratorTuple > make_zip_iterator(IteratorTuple iterators);

Description

Creates a zip_iterator for iterators.

For example, to zip together iterators from three vectors (a, b, and c):

auto zipped = boost::compute::make_zip_iterator(
    boost::make_tuple(a.begin(), b.begin(), c.begin())
);

Parameters:

iterators

a tuple of input iterators to zip together

Returns:

a zip_iterator for iterators


PrevUpHomeNext