Iterator library
(iterator) 5(c++17 ) 6(c++17 ) , , .
Iterator categories
: LegacyInputIterator, LegacyOutputIterator, LegacyForwardIterator, LegacyBidirectionalIterator, LegacyRandomAccessIterator, LegacyContiguousIterator
. . -- , LegacyRandomAccessIterator LegacyRandomAccessIterator .
OutputInterator LegacyContiguousIterator ( LegacyRandomAccessIterator) ( LegacyInputIterator) . LegacyOutputIterator . mutable , . Non-mutable constant .
| Iterator category | Defined operations | |||
|---|---|---|---|---|
LegacyRandomAccessIterator
|
LegacyBidirectionalIterator
|
LegacyForwardIterator
|
LegacyInputIterator
|
|
| ||||
| ||||
| ||||
|
Iterators that fall into one of the above categories and also meet the requirements of | ||||
LegacyOutputIterator
|
| |||
|
Iterators that fall into one of the above categories and also meet the requirements of | ||||
LegacyContiguousIterator
|
| |||
Iterator primitives
| provides uniform interface to the properties of an iterator (class template) | |
| empty class types used to indicate iterator categories (class) | |
| the basic iterator (class template) |
Iterator adaptors
| iterator adaptor for reverse-order traversal (class template) | |
(C++11) |
iterator adaptor which dereferences to an rvalue reference (class template) |
(C++11) |
creates a std::move_iterator of type inferred from the argument (function template) |
| iterator adaptor for insertion at the end of a container (class template) | |
| creates a std::back_insert_iterator of type inferred from the argument (function template) | |
| iterator adaptor for insertion at the front of a container (class template) | |
| creates a std::front_insert_iterator of type inferred from the argument (function template) | |
| iterator adaptor for insertion into a container (class template) | |
| creates a std::insert_iterator of type inferred from the argument (function template) |
Stream iterators
| input iterator that reads from std::basic_istream (class template) | |
| output iterator that writes to std::basic_ostream (class template) | |
| input iterator that reads from std::basic_streambuf (class template) | |
| output iterator that writes to std::basic_streambuf (class template) |
Iterator operations
<iterator> . | |
| advances an iterator by given distance (function) | |
| returns the distance between two iterators (function) | |
(C++11) |
increment an iterator (function) |
(C++11) |
decrement an iterator (function) |
Range access
<iterator> . | |
(C++11) (C++14) |
returns an iterator to the beginning of a container or array (function) |
(C++11) (C++14) |
returns an iterator to the end of a container or array (function) |
(C++14) |
returns a reverse iterator to a container or array (function) |
(C++14) |
returns a reverse end iterator for a container or array (function) |