Condition.wait

Suspends the calling thread until a notification occurs or until the supplied time period has elapsed.

  1. void wait()
  2. bool wait(Duration val)
    class Condition
    bool
    wait
    (
    Duration val
    )

Parameters

val Duration

The time to wait.

In: val must be non-negative.

Return Value

Type: bool

true if notified before the timeout and false if not.

Throws

SyncError on error.

Meta