std::recursive_mutex
Aus 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. |
| Defined in header <mutex>
|
||
| class recursive_mutex; |
(seit C++11) | |
Die
recursive_mutex Klasse ist ein Synchronisierungsgrundeinheit, die verwendet werden, um gemeinsame Daten aus gleichzeitig von mehreren Threads zugegriffen schützen können .Original:
The
recursive_mutex class is a synchronization primitive that can be used to protect shared data from being simultaneously accessed by multiple threads.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.
recursive_mutex bietet exklusive, rekursive Eigentum Semantik:Original:
recursive_mutex offers exclusive, recursive ownership semantics: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.
- Ein aufrufenden Threads' besitzt eine
recursive_mutexfür eine Zeitspanne, die beim Aufrufen erfolgreich entwederlockodertry_lockbeginnt. Während dieser Zeit kann sich der Faden zusätzliche Anrufelockodertry_lockmachen. Der Zeitraum des Besitzes endet, wenn der Thread macht eine passende Anzahl von Anrufenunlock.Original:A calling thread owns arecursive_mutexfor a period of time that starts when it successfully calls eitherlockortry_lock. During this period, the thread may make additional calls tolockortry_lock. The period of ownership ends when the thread makes a matching number of calls tounlock.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions. - Wenn ein Thread eine
recursive_mutexbesitzt, werden alle anderen Threads blockieren (für Anrufe inlock) oder erhalten eine false Rückgabewert (fürtry_lock), wenn sie das Eigentum an derrecursive_mutexbehaupten versuchen .Original:When a thread owns arecursive_mutex, all other threads will block (for calls tolock) or receive a false return value (fortry_lock) if they attempt to claim ownership of therecursive_mutex.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions. - Die maximale Anzahl, wie oft ein
recursive_mutexgesperrt werden kann, ist unbegrenzt, aber nach, dass Anzahl erreicht ist, werden Anrufe anlockwird std::system_error werfen und rufttry_lockzurückkehren false .Original:The maximum number of times that arecursive_mutexmay be locked is unspecified, but after that number is reached, calls tolockwill throw std::system_error and calls totry_lockwill return false.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Das Verhalten eines Programms ist nicht definiert, wenn ein
recursive_mutex zerstört wird, während noch von einem Thread gehört. Die recursive_mutex Klasse ist nicht kopierbar .Original:
The behavior of a program is undefined if a
recursive_mutex is destroyed while still owned by some thread. The recursive_mutex class is non-copyable.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.
[Bearbeiten] Mitglied Typen
| Mitglied Typ
Original: Member type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
Definition |
native_handle_type
|
Implementierung definiert
Original: implementation-defined The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[Bearbeiten] Member-Funktionen
| konstruiert den Mutex (öffentliche Elementfunktion) | |
Original: Locking The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
| sperrt den Mutex, blockiert wenn der Mutex nicht verfügbar ist (öffentliche Elementfunktion) | |
| versucht den Mutex zu sperren,kehrt zurueck wenn der Mutex nicht verfügbar ist (öffentliche Elementfunktion) | |
| entsperrt den Mutex (öffentliche Elementfunktion) | |
Original: Native handle The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
| gibt das zugrunde liegende implementierungsabhängige Thread-Handle zurück (öffentliche Elementfunktion) |

