Namensräume
Varianten
Aktionen

Thread support library

Aus cppreference.com
< cpp


 
 
Thema Support-Bibliothek
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.
thread(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.
get_id(C++11)
yield(C++11)
sleep_for(C++11)
sleep_until(C++11)
Gegenseitigen Ausschluss
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.
mutex(C++11)
timed_mutex(C++11)
Generische Sperrverwaltung
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.
lock_guard(C++11)
unique_lock(C++11)
defer_lock_t
try_to_lock_t
adopt_lock_t
(C++11)
(C++11)
(C++11)
lock(C++11)
try_lock(C++11)
defer_lock
try_to_lock
adopt_lock
(C++11)
(C++11)
(C++11)
Zustand Variablen
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.
condition_variable(C++11)
condition_variable_any(C++11)
notify_all_at_thread_exit(C++11)
cv_status(C++11)
Futures
Original:
Futures
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
promise(C++11)
future(C++11)
shared_future(C++11)
packaged_task(C++11)
async(C++11)
launch(C++11)
future_status(C++11)
future_error(C++11)
future_category(C++11)
future_errc(C++11)
 

C++ includes built-in support for threads, mutual exclusion, condition variables, and futures.

Inhaltsverzeichnis

[Bearbeiten] Threads

Threads enable programs to execute across several processor cores.

Defined in header <thread>
(C++11)
verwaltet einen eigenen Thread
Original:
manages a separate thread
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
Functions managing the current thread
Defined in namespace this_thread
(C++11)
suggests that the implementation reschedule execution of threads
(Funktion) [edit]
(C++11)
liefert die Thread-ID des aktuellen Threads
Original:
returns the thread id of the current thread
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Funktion) [edit]
(C++11)
stoppt die Ausführung des aktuellen Threads für eine bestimmte Zeitdauer
Original:
stops the execution of the current thread for a specified time duration
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Funktion) [edit]
stops the execution of the current thread until a specified time point
(Funktion) [edit]

[Bearbeiten] Gegenseitigen Ausschluss

Mutual exclusion algorithms prevent multiple threads from simultaneously accessing shared resources. This prevents data races and provides support for synchronization between threads.

Defined in header <mutex>
(C++11)
bietet grundlegende gegenseitige Ausgrenzung Anlage
Original:
provides basic mutual exclusion facility
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
bietet gegenseitigen Ausschluss Anlage, die mit einem Timeout Sperren implementiert
Original:
provides mutual exclusion facility which implements locking with a timeout
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
stellt wechselseitigen Ausschluss Anlage, die rekursiv von demselben Thread gesperrt werden
Original:
provides mutual exclusion facility which can be locked recursively by the same thread
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
stellt wechselseitigen Ausschluss Anlage, die recursively
kann durch das gleiche Gewinde und Arbeitsgeräte Verriegeln mit einem Timeout verriegelt werden
Original:
provides mutual exclusion facility which can be locked recursively
by the same thread and implements locking with a timeout
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
Generic mutex management
implementiert eine streng bereichsbasierte Mutex Eigentums-Wrapper
Original:
implements a strictly scope-based mutex ownership wrapper
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klassen-Template) [edit]
implementiert beweglichen Mutex Eigentums-Wrapper
Original:
implements movable mutex ownership wrapper
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klassen-Template) [edit]
Tag-Typ verwendet werden, um Sperrstrategie angeben
Original:
tag type used to specify locking strategy
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
tag Konstanten verwendet werden, um Sperrstrategie angeben
Original:
tag constants used to specify locking strategy
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(konstanten) [edit]
Generic locking algorithms
(C++11)
Versuche, das Eigentum an Mutexe via wiederholten Aufforderungen an try_lock erhalten
Original:
attempts to obtain ownership of mutexes via repeated calls to try_lock
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Funktions-Template) [edit]
(C++11)
sperrt angegebenen Mutexe, Blöcke wenn überhaupt verfügbar sind
Original:
locks specified mutexes, blocks if any are unavailable
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Funktions-Template) [edit]
Rufen Sie einmal
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.
(C++11)
Hilfsobjekt um sicherzustellen, dass call_once die Funktion aufruft nur einmal
Original:
helper object to ensure that call_once invokes the function only once
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
(C++11)
ruft eine Funktion nur einmal, auch wenn von mehreren Threads aufgerufen
Original:
invokes a function only once even if called from multiple threads
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Funktions-Template) [edit]

[Bearbeiten] Zustand Variablen

A condition variable is a synchronization primitive that allows multiple threads to communicate with eachother. It allows some number of threads to wait (possibly with a timeout) for notification from another thread that they may proceed. A condition variable is always associated with a mutex.

Defined in header <condition_variable>
provides a condition variable associated with a std::unique_lock
(Klasse)
provides a condition variable associated with any lock type
(Klasse)
schedules a call to notify_all to be invoked when this thread is completely finished
(Funktion)
(C++11)
lists the possible results of timed waits on condition variables
(enum)

[Bearbeiten] Futures

The standard library provides facilities to obtain values that are returned and to catch exceptions that are thrown by asynchronous tasks (i.e. functions launched in separate threads). These values are communicated in a shared state, in which the asynchronous task may write its return value or store an exception, and which may be examined, waited for, and otherwise manipulated by other threads that hold instances of std::future or std::shared_future that reference that shared state.

Defined in header <future>
(C++11)
speichert einen Wert für asynchrone Abruf
Original:
stores a value for asynchronous retrieval
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klassen-Template) [edit]
Pakete eine Funktion, um den Rückgabewert für asynchrone Abruf speichern
Original:
packages a function to store its return value for asynchronous retrieval
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klassen-Template) [edit]
(C++11)
wartet auf einen Wert, der asynchron ist
Original:
waits for a value that is set asynchronously
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klassen-Template) [edit]
wartet auf einen Wert (eventuell von anderen Futures verwiesen wird), die asynchron ist
Original:
waits for a value (possibly referenced by other futures) that is set asynchronously
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klassen-Template) [edit]
(C++11)
betreibt eine Funktion asynchron (möglicherweise in einem neuen Thread) und gibt einen std::future, die das Ergebnis halten wird
Original:
runs a function asynchronously (potentially in a new thread) and returns a std::future that will hold the result
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Funktions-Template) [edit]
(C++11)
gibt die Markteinführung Politik für std::async
Original:
specifies the launch policy for std::async
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(enum) [edit]
gibt die Ergebnisse der zeitlich wartet auf std::future und std::shared_future durchgeführt
Original:
specifies the results of timed waits performed on std::future and std::shared_future
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(enum) [edit]
Future errors
meldet einen Fehler im Zusammenhang mit Futures oder Versprechungen
Original:
reports an error related to futures or promises
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Klasse) [edit]
identifiziert die Zukunft error Kategorie
Original:
identifies the future error category
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(Funktion) [edit]
auf die künftigen Fehlercodes
Original:
identifies the future error codes
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(enum) [edit]