std::future::share
De 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. |
std::shared_future<T> share(); |
||
Transfère l'état partagé de *this à un objet std::shared_future. Plusieurs objets std::shared_future peut référencer le même état partagé, ce qui n'est pas possible avec std::future .
Original:
Transfers the shared state of *this to a std::shared_future object. Multiple std::shared_future objects may reference the same shared state, which is not possible with std::future.
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.
Après avoir appelé
share
sur un std::future, valid() == false .Original:
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.
Sommaire |
[modifier] Paramètres
(Aucun)
Original:
(none)
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.
[modifier] Retourne la valeur
Un objet std::shared_future contenant l'état partagé précédemment détenu par *this
Original:
A std::shared_future object containing the shared state previously held by *this
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.
[modifier] Exemple
This section is incomplete Reason: no example |
[modifier] Voir aussi
(C++11) |
attend une valeur (peut-être référencé par d'autres futurs) qui est fixé de manière asynchrone Original: waits for a value (possibly referenced by other futures) that is set asynchronously The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe générique) |