Aracılığıyla paylaş


Thread.Interrupted Method

Definition

Tests whether the current thread has been interrupted.

[Android.Runtime.Register("interrupted", "()Z", "")]
public static bool Interrupted ();
[<Android.Runtime.Register("interrupted", "()Z", "")>]
static member Interrupted : unit -> bool

Returns

true if the current thread has been interrupted; false otherwise.

Attributes

Remarks

Tests whether the current thread has been interrupted. The interrupted status of the thread is cleared by this method. In other words, if this method were to be called twice in succession, the second call would return false (unless the current thread were interrupted again, after the first call had cleared its interrupted status and before the second call had examined it).

A thread interruption ignored because a thread was not alive at the time of the interrupt will be reflected by this method returning false.

Java documentation for java.lang.Thread.interrupted().

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

See also