std::promise::get_future
Da 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::future<R> get_future(); |
(desde C++11) | |
Retorna um objeto futuro associado com o mesmo estado compartilhado como *this.
Original:
Returns a future object associated with the same shared state as *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.
Exceção é lançada se *this não tem estado compartilhado ou
get_future
já foi chamado.Original:
Exception is thrown if *this has no shared state or
get_future
has already been called.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.
[editar] Parâmetros
(Nenhum)
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.
[editar] Valor de retorno
Um futuro referindo-se ao estado compartilhado de *this
Original:
A future referring to the shared state of *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.
[editar] Exceções
std::future_error com as seguintes condições:
Original:
std::future_error on the following conditions:
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.
- *this não tem estado compartilhado. A categoria de erro é definido para no_state.Original:*this has no shared state. The error category is set to no_state.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
-
get_future()
já foi chamado em uma promessa com o mesmo estado compartilhado como *this. A categoria de erro é definido para future_already_retrieved.Original:get_future()
has already been called on a promise with the same shared state as *this. The error category is set to future_already_retrieved.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.