std::map::at
Da cppreference.com.
![]() | Questa pagina è stata tradotta in modo automatico dalla versione in ineglese della wiki usando Google Translate. La traduzione potrebbe contenere errori e termini strani. Muovi il puntatore sopra al testo per vedere la versione originale. Puoi aiutarci a correggere gli gli errori. Per ulteriori istruzioni clicca qui. |
T& at(const Key& key ); | (1) | (dal C++11) |
const T & at(const Key& key )const; | (2) | (dal C++11) |
Restituisce un riferimento al valore mappato dell'elemento con tasto equivalente a
key
. Se tale elemento non esiste, un'eccezione di tipo std::out_of_range viene gettato.Original:
Returns a reference to the mapped value of the element with key equivalent to
key
. If no such element exists, an exception of type std::out_of_range is thrown.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Indice |
[modifica]Parametri
key | - | la chiave dell'elemento da trovare Original: the key of the element to find The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[modifica]Valore di ritorno
Riferimento al valore mappato dell'elemento richiesto
Original:
Reference to the mapped value of the requested element
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[modifica]Eccezioni
std::out_of_range se il contenitore non ha un elemento con la
key
specificatoOriginal:
std::out_of_range if the container does not have an element with the specified
key
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[modifica]Complessità
Logarithmic in the size of the container.
[modifica]Vedi anche
accedere elemento specificato Original: access specified element The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) |