Share via


CountDownLatch.CountDown Method

Definition

Decrements the count of the latch, releasing all waiting threads if the count reaches zero.

[Android.Runtime.Register("countDown", "()V", "GetCountDownHandler")]
public virtual void CountDown ();
[<Android.Runtime.Register("countDown", "()V", "GetCountDownHandler")>]
abstract member CountDown : unit -> unit
override this.CountDown : unit -> unit
Attributes

Remarks

Decrements the count of the latch, releasing all waiting threads if the count reaches zero.

If the current count is greater than zero then it is decremented. If the new count is zero then all waiting threads are re-enabled for thread scheduling purposes.

If the current count equals zero then nothing happens.

Java documentation for java.util.concurrent.CountDownLatch.countDown().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to