std::get(std::array)
Aus cppreference.com
![]() |
This page has been machine-translated from the English version of the wiki using Google Translate.
The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
template<size_t I, class T, size_t N > T& get( array<T,N>& a ); |
(1) | (seit C++11) |
template<size_t I, class T, size_t N > T&& get( array<T,N>&& a ); |
(2) | (seit C++11) |
template<size_t I, class T, size_t N > const T& get( const array<T,N>& a ); |
(3) | (seit C++11) |
Extrahiert die
Ith
element aus dem Array . Original:
Extracts the
Ith
element element from the array. 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.
I
muss ein Integer-Wert im Bereich [0, N)
sein. Dies wird bei der Kompilierung durchgesetzt zu at()
entgegengesetzt oder operator[]()
.Original:
I
must be an integer value in range [0, N)
. This is enforced at compile time as opposed to at()
or operator[]()
.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.
Inhaltsverzeichnis |
[Bearbeiten] Parameter
a | - | Array, dessen Inhalt zu extrahieren
Original: array whose contents to extract The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[Bearbeiten] Rückgabewert
1)Verweis auf die
2) Ith
Element a
.Original:
Reference to the
Ith
element of a
.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.
Rvalue Verweis auf das Element
3) Ith
a
, sofern das Element der L-Wert-Referenz-Typ, wobei in diesem Fall L-Wert Verweis zurückgegeben .Original:
Rvalue reference to the
Ith
element of a
, unless the element is of lvalue reference type, in which case lvalue reference is returned.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.
Const Verweis auf die
Ith
Element a
.Original:
Const reference to the
Ith
element of a
.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.
[Bearbeiten] Ausnahmen
[Bearbeiten] Beispiel
Output:
(1, 2, 3)
[Bearbeiten] Siehe auch
Zugriff auf angegebene Element 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. (öffentliche Elementfunktion) | |
Zugriff auf angegebene Element mit Überprüfung von Grenzen Original: access specified element with bounds checking The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (öffentliche Elementfunktion) | |
Zugriff auf das angegebene Element des Tupels Original: tuple accesses specified element The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (Funktions-Template) | |
(C++11) |
greift ein Element eines pair Original: accesses an element of a pair The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (Funktions-Template) |