![]() |
Home | Libraries | People | FAQ | More |
boost::unit_test::data::monomorphic::zip — Zip datasets.
// In header: <boost/test/data/monomorphic/zip.hpp> template<typename DS1, typename DS2> class zip { public: // member classes/structs/unions struct iterator : public boost::unit_test::data::monomorphic::dataset< T >::iterator { // types typedef monomorphic::traits< T >::ref_type ref_type; // construct/copy/destruct explicit iterator(ds1_iter_ptr, ds2_iter_ptr); // public member functions virtual ref_type operator*(); virtual void operator++(); }; enum @9 { arity = = boost::decay<DS1>::type::arity + boost::decay<DS2>::type::arity }; // construct/copy/destruct zip(DS1 &&, DS2 &&, data::size_t); zip(zip &&); // public member functions virtual data::size_t size() const; virtual iter_ptr begin() const; };
A zip of two datasets is a dataset whose arity is the sum of the operand datasets arity. The size is given by the function creating the instance (see operator^
on datasets).
zip
public
construct/copy/destructzip(DS1 && ds1, DS2 && ds2, data::size_t size);Constructor.
The datasets are moved and not copied.
zip(zip && j);Move constructor.
zip
public member functionsvirtual data::size_t size() const;Dataset size.
virtual iter_ptr begin() const;Iterator to use to iterate over this dataset.