Bibliothque d'itrateurs
La bibliothque d'itrateurs dfinit cinq catgories d'itrateurs ainsi qu'une classe d'itrateur "gnrique", des adaptateurs et des fonctions utilitaires.
Catgories d'itrateurs
Il existe cinq catgories d'itrateurs: InputIterator, OutputIterator, ForwardIterator, BidirectionalIterator et RandomAccessIterator .
Au lieu d'tre dfinis par des types spcifiques, chaque catgorie d'itrateur est dfini par les oprations qui peuvent tre effectues sur celui-ci (c'est dire, des concepts). Cette dfinition signifie que n'importe quel type qui prend en charge les oprations ncessaires peut tre utilis comme un itrateur -- par exemple, un pointeur prend en charge toutes les oprations requises par RandomAccessIterator, donc un pointeur peut tre utilis partout o un RandomAccessIterator est attendu.
Quatre des cinq catgories d'itrateurs peuvent tre organiss en une hirarchie, o les catgories d'itrateurs plus puissants (par exemple RandomAccessIterator) supportent les oprations de catgories moins puissantes (par exemple InputIterator.
Si un itrateur est dans une de ces catgories et vrifie aussi les qualits requises d'un OutputIterator, alors il est appel un itrateur mutable et supporte la fois entre et sortie. Les itrateurs immuables sont appels itrateurs constants.
| Catgories d'itrateurs | Oprations dfinies | |||
|---|---|---|---|---|
RandomAccessIterator
|
BidirectionalIterator
|
ForwardIterator
|
InputIterator
|
|
| ||||
| ||||
| ||||
|
Les itrateurs de l'une des catgories ci-dessus qui respectent galement le concept de | ||||
OutputIterator
|
| |||
Primitives d'itrateurs
fournit une interface uniforme pour les proprits d'un itrateur Original: provides uniform interface to the properties of an iterator The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
types de classes vides utiliss pour indiquer les catgories d'itrateurs Original: empty class types used to indicate iterator categories The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe) | |
l'itrateur de base Original: the basic iterator The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
Adaptateurs d'itrateurs
Adaptateur pour itrateur inverse-ordre Original: iterator adaptor for reverse-order traversal The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
(C++11) |
Adaptateur itrateur qui drfrence une rfrence rvalue Original: iterator adaptor which dereferences to an rvalue reference The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) |
(C++11) |
cre un std::move_iterator de type infr partir de l'argument Original: creates a std::move_iterator of type inferred from the argument The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction gnrique) |
Adaptateur itrateur pour l'insertion la fin d'un rcipient Original: iterator adaptor for insertion at the end of a container The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
cre un std::back_insert_iterator de type infr partir de l'argument Original: creates a std::back_insert_iterator of type inferred from the argument The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction gnrique) | |
Adaptateur itrateur pour l'insertion l'avant d'un conteneur Original: iterator adaptor for insertion at the front of a container The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
cre un std::front_insert_iterator de type infr partir de l'argument Original: creates a std::front_insert_iterator of type inferred from the argument The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction gnrique) | |
Adaptateur itrateur pour l'insertion dans un rcipient Original: iterator adaptor for insertion into a container The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
cre un std::insert_iterator de type infr partir de l'argument Original: creates a std::insert_iterator of type inferred from the argument The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction gnrique) | |
Itrateurs de flux
itrateur d'entre qui lit std::basic_istream Original: input iterator that reads from std::basic_istream The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
itrateur de sortie qui crit dans std::basic_ostream Original: output iterator that writes to std::basic_ostream The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
itrateur d'entre qui lit std::basic_streambuf Original: input iterator that reads from std::basic_streambuf The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
itrateur de sortie qui crit dans std::basic_streambuf Original: output iterator that writes to std::basic_streambuf The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe gnrique) | |
Oprations sur les itrateurs
Defined in header
<iterator> | |
avance un itrateur par distance donne Original: advances an iterator by given distance The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction) | |
renvoie la distance entre deux itrateurs Original: returns the distance between two iterators The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction) | |
(C++11) |
incrmenter un itrateur Original: increment an iterator The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction) |
(C++11) |
dcrmenter un itrateur Original: decrement an iterator The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction) |
Accs des plages
Defined in header
<iterator> | |
(C++11) |
retourne un itrateur pour le dbut d'un conteneur ou d'un tableau Original: returns an iterator to the beginning of a container or array The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction) |
(C++11) |
retourne un itrateur l'extrmit d'un conteneur ou d'un tableau Original: returns an iterator to the end of a container or array The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction) |