Espacios de nombres
Variantes
Acciones

mtx_timedlock

De cppreference.com
< c‎ | thread

 
 
Tema Biblioteca de ayuda
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.
Exclusión mutua
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.
mtx_init
mtx_lock
mtx_timedlock
mtx_trylock
Llame a la vez
Original:
Call once
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Las variables de condición
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.
Almacenamiento local de subprocesos
Original:
Thread-local storage
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
 
Defined in header <threads.h>
int mtx_timedlock( mtx_t *restrict mutex,
                   const struct timespec *restrict time_point );
(desde C11)
Bloquea el subproceso actual hasta que el mutex apuntado por mutex está bloqueado o hasta el punto TIME_UTC basado en el tiempo señalado por time_point se ha llegado .
Original:
Blocks the current thread until the mutex pointed to by mutex is locked or until the TIME_UTC based time point pointed to by time_point has been reached.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
El comportamiento no está definido si el subproceso actual ya ha bloqueado el mutex y la exclusión mutua no es recursiva .
Original:
The behavior is undefined if the current thread has already locked the mutex and the mutex is not recursive.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
El comportamiento no está definido si la exclusión mutua no es compatible tiempo de espera .
Original:
The behavior is undefined if the mutex does not support timeout.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[editar] Parámetros

mutex -
puntero a la exclusión mutua para bloquearlo
Original:
pointer to the mutex to lock
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
time_point -
puntero hasta el tiempo de espera para esperar hasta que
Original:
pointer to the timeout time to wait until
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

thrd_success si tiene éxito, thrd_timedout si el tiempo de espera antes de que se haya alcanzado el mutex está bloqueado, si un thrd_error occurrs error .
Original:
thrd_success if successful, thrd_timedout if the timeout time has been reached before the mutex is locked, thrd_error if an error occurrs.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[editar] Ver también

bloquea hasta que cierres un mutex
Original:
blocks until locks a mutex
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(función) [edit]
bloquea un mutex o devoluciones sin bloquear si ya está bloqueado
Original:
locks a mutex or returns without blocking if already locked
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(función) [edit]
desbloquea un mutex
Original:
unlocks a mutex
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(función) [edit]