|
Boost Users : |
Subject: Re: [Boost-users] implementing custom iterators
From: Nathan Ridge (zeratul976_at_[hidden])
Date: 2012-03-24 16:00:10
> Hello,
>
> Can you help choosing between boost/operators.hpp(iterator_helper) and
> boost::iterator_facade for the implementation of a number of custom
> c++11-compliant iterators?
>
> What questions are to be asked? How to choose between the 2 libraries?
>
> rds,
> MM
I've always used iterator_facade [1] or iterator_adaptor [2]. This is the first
time I hear about iterator_helper.
In terms of choosing between iterator_facade and iterator_adaptor, I believe
iterator_adaptor is meant to be used when your iterator wraps some underlying
iterator, and iterator_facade when your iterator does something different/more
than that. iterator_adaptor is implemented using iterator_facade.
Regards,
Nate
[1] http://www.boost.org/doc/libs/1_49_0/libs/iterator/doc/iterator_facade.html
[2] http://www.boost.org/doc/libs/1_49_0/libs/iterator/doc/iterator_adaptor.html
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net