Namespaces
Variants
Actions

C++ named requirements: LegacyIterator

From cppreference.com
< cpp‎ | named req
 
 
C++ named requirements
 

The LegacyIterator requirements describe types that can be used to identify and traverse the elements of a container.

LegacyIterator is the base set of requirements used by other iterator types: LegacyInputIterator, LegacyOutputIterator, LegacyForwardIterator, LegacyBidirectionalIterator, and LegacyRandomAccessIterator. Iterators can be thought of as an abstraction of pointers.

All the categories of iterators require only those functions that are realizable for a given category in constant time (amortized). Therefore, requirement tables and concept definitions(since C++20) for the iterators do not specify complexity.

Contents

[edit] Requirements

The type It satisfies LegacyIterator if