Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

iterator.hpp

Introduction
Class template iterator
Class template iterator constructors
Class template iterators
Class template iterators nested types
Class template iterators static functions
Functions
Example

<boost/python/iterator.hpp> provides types and functions for creating Python iterators from C++ Containers and Iterators. Note that if your class_ supports random-access iterators, implementing __getitem__ (also known as the Sequence Protocol) may serve you better than using this facility: Python will automatically create an iterator type for you (see iter()), and each access can be range-checked, leaving no possiblity of accessing through an invalidated C++ iterator.


PrevUpHomeNext