Espaces de noms
Variantes
Affichages
Actions

std::deque::emplace

De cppreference.com
< cpp‎ | container‎ | deque

 
 
 
std :: deque
Les fonctions membres
Original:
Member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
deque::deque
deque::~deque
deque::operator=
deque::assign
deque::get_allocator
Elément d'accès
Original:
Element access
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
deque::front
deque::back
Les itérateurs
Original:
Iterators
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
deque::begin
deque::cbegin

(C++11)
deque::end
deque::cend

(C++11)
deque::rbegin
deque::crbegin

(C++11)
deque::rend
deque::crend

(C++11)
Capacité
Original:
Capacity
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
deque::empty
deque::size
deque::max_size
deque::shrink_to_fit
Modificateurs
Original:
Modifiers
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
deque::clear
deque::insert
deque::emplace
deque::erase
deque::push_front
deque::emplace_front
deque::pop_front
deque::push_back
deque::emplace_back
deque::pop_back
deque::resize
deque::swap
 
template< class... Args >
iterator emplace( const_iterator pos, Args&&... args );
(depuis C++11)
Insère un nouvel élément dans le conteneur directement devant pos. L'élément est réalisé in-situ, c'est à dire pas de copie ou les opérations de déplacement sont effectuées. Le constructeur de l'élément est appelé avec l'std::forward<Args>(args)... arguments. Le type d'élément doit être EmplaceConstructible, MoveInsertable and MoveAssignable .
Original:
Inserts a new element into the container directly before pos. The element is constructed in-place, i.e. no copy or move operations are performed. The constructor of the element is called with the arguments std::forward<Args>(args).... The element type must be EmplaceConstructible, MoveInsertable and MoveAssignable.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

All iterators are invalidated. References are invalidated too, unless pos == begin() or pos == end(), in which case they are not invalidated.

Sommaire

[modifier] Paramètres

pos -
itérateur avant que le nouvel élément sera construit
Original:
iterator before which the new element will be constructed
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
args -
arguments à transmettre au constructeur de l'élément
Original:
arguments to forward to the constructor of the element
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[modifier] Retourne la valeur

Itérateur pointant vers l'élément mis en place .
Original:
Iterator pointing to the emplaced element.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[modifier] Complexité

Linear in the lesser of the distances between pos and either of the ends of the container.

[modifier] Exceptions

Si une exception est levée (par exemple par le constructeur), le conteneur n'est pas modifié, comme si cette fonction n'a jamais été appelé (garantie exception fort) .
Original:
If an exception is thrown (e.g. by the constructor), the container is left unmodified, as if this function was never called (strong exception guarantee).
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[modifier] Voir aussi

insère des éléments
Original:
inserts elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction membre publique) [edit]