hash_multimap::crbegin
Nota
Esta API está obsoleta.La alternativa es unordered_multimap (Clase).
Devuelve un iterador const que dirige el primer elemento de un hash_multimap invertido.
const_reverse_iterator crbegin( ) const;
Valor devuelto
Un iterador bidireccional inversos const que dirige el primer elemento de hash_multimap (Clase) o un direccionamiento invertido que había sido el último elemento de hash_multimapunreversed.
Comentarios
crbegin se utiliza con un hash_multimap invertido igual que hash_multimap::begin se utiliza con hash_multimap.
Con el valor devuelto de crbegin, el objeto de hash_multimap no puede modificarse.
crbegin se puede utilizar para recorrer hash_multimap hacia atrás.
En Visual C++ .NET 2003, los miembros de los archivos de encabezado <hash_map> y <hash_set> ya no están en el espacio de nombres std, sino que se han movido al espacio de nombres stdext. Vea El espacio de nombres stdext para obtener más información.
Ejemplo
// hash_multimap_crbegin.cpp
// compile with: /EHsc
#include <hash_multimap>
#include <iostream>
int main( )
{
using namespace std;
using namespace stdext;
hash_multimap <int, int> hm1;
hash_multimap <int, int> :: const_reverse_iterator hm1_crIter;
typedef pair <int, int> Int_Pair;
hm1.insert ( Int_Pair ( 3, 30 ) );
hm1_crIter = hm1.crbegin( );
cout << "The first element of the reversed hash_multimap hm1 is "
<< hm1_crIter -> first << "." << endl;
}
Requisitos
Encabezado: <hash_map>
Espacio de nombres: stdext