Espacios de nombres
Variantes
Acciones

std::atomic::exchange

De cppreference.com
< cpp‎ | atomic‎ | atomic

 
 
Operaciones de biblioteca Atómica
Tipos
Original:
Types
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
Funciones
Original:
Functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Banderas atómicas
Original:
Atomic flags
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Inicialización
Original:
Initialization
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Memoria pedido
Original:
Memory ordering
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
 
std::atomic
Las funciones miembro
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.
atomic::exchange
Funciones especializadas miembros
Original:
Specialized member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
 
T exchange( T desired, memory_order = std::memory_order_seq_cst );
(desde C++11)
T exchange( T desired, memory_order = std::memory_order_seq_cst ) volatile;
(desde C++11)
Atómicamente sustituye el valor subyacente con desired. La operación es de lectura-modificación-escritura de la operación. Memoria se ve afectada de acuerdo con el valor de memory_order .
Original:
Atomically replaces the underlying value with desired. The operation is read-modify-write operation. Memory is affected according to the value of memory_order.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Contenido

[editar] Parámetros

desired -
valor a asignar
Original:
value to assign
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
memory_order -
restricciones de memoria el orden de hacer cumplir
Original:
memory order constraints to enforce
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

El valor de la variable atómica antes de la llamada .
Original:
The value of the atomic variable before the call.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[editar] Excepciones

noexcept specification:  
noexcept
  (desde C++11)

[editar] Ver también

atómicamente reemplaza el valor del objeto atómico con no atómico argumento y devuelve el valor antiguo de la atómica
Original:
atomically replaces the value of the atomic object with non-atomic argument and returns the old value of the atomic
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(plantilla de función) [editar]