◐ Shell
clean mode source ↗

std::shared_future::wait – cppreference.com

Aus cppreference.com

<metanoindex/>

<tbody> </tbody>

template< class Rep, class Period > std::future_status wait_for( const std::chrono::duration<Rep,Period>& timeout_duration );

Wartet, bis das Ergebnis zur Verfügung stehen. Blöcke bis angegebenen timeout_duration abgelaufen ist oder das Ergebnis zur Verfügung steht, was zuerst eintritt. Liefert den Wert kennzeichnet den Zustand des Ergebnisses. Kann länger als timeout_duration blockieren .

Original:

Waits for the result to become available. Blocks until specified timeout_duration has elapsed or the result becomes available, whichever comes first. Returns value identifies the state of the result. May block for longer than timeout_duration.

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Parameter

timeout_duration -

maximale Dauer für zu blockieren

Original:

maximum duration to block for

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Rückgabewert

Constant Explanation
future_status::deferred The function to calculate the result has not been started yet
future_status::ready The result is ready
future_status::timeout The timeout has expired

Ausnahmen

(None)

Original:

(none)

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Beispiel

Siehe auch

wartet darauf dass das Ergebnis verfügbar wird

Original:

waits for the result to become available

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.


(öffentliche Elementfunktion) [edit]

wartet auf das Ergebnis liefert, wenn es nicht verfügbar ist, bis spezifizierte Zeit erreicht worden ist

Original:

waits for the result, returns if it is not available until specified 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.


(öffentliche Elementfunktion) [edit]