Espaços nominais
Variantes
Acções

std::swap(std::promise)

Da cppreference.com
< cpp‎ | thread‎ | promise

 
 
Biblioteca de suporte a discussão
Threads
Original:
Threads
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
this_thread namespace
Original:
this_thread namespace
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
(C++11)
(C++11)
Exclusão mútua
Original:
Mutual exclusion
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
Gestão de bloqueio genérico
Original:
Generic lock management
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
(C++11)
(C++11)(C++11)(C++11)
Variáveis ​​de condição
Original:
Condition variables
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
Futuros
Original:
Futures
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
(C++11)
(C++11)
 
std::promise
Funções de membro
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.
promise::promise
promise::~promise
promise::operator=
promise::swap
Obtendo o resultado
Original:
Getting the result
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
promise::get_future
Definir o resultado
Original:
Setting the result
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
promise::set_value
promise::set_value_at_thread_exit
promise::set_exception
promise::set_exception_at_thread_exit
 
Definido no cabeçalho <future>
template<class R >
void swap( promise<R>&lhs, promise<R>&rhs );
(desde C++11)
Especializa o algoritmo std::swap para std::promise. Bolsas de valores do estado compartilhado de lhs com a de rhs. Efetivamente chama lhs.swap(rhs).
Original:
Specializes the std::swap algorithm for std::promise. Exchanges the shared state of lhs with that of rhs. Effectively calls lhs.swap(rhs).
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Índice

[editar]Parâmetros

lhs, rhs -
promessas cujos estados para trocar
Original:
promises whose states to swap
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[editar]Valor de retorno

(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.

[editar]Exceções

noexcept specification:  
noexcept
  (desde C++11)

[editar]Exemplo

[editar]Veja também

troca dois objetos promessa
Original:
swaps two promise objects
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(função pública membro)[edit]
close