Udostępnij za pośrednictwem


CountedCompleter.NextComplete Method

Definition

If this task does not have a completer, invokes ForkJoinTask#quietlyComplete and returns null.

[Android.Runtime.Register("nextComplete", "()Ljava/util/concurrent/CountedCompleter;", "", ApiSince=24)]
public Java.Util.Concurrent.CountedCompleter? NextComplete ();
[<Android.Runtime.Register("nextComplete", "()Ljava/util/concurrent/CountedCompleter;", "", ApiSince=24)>]
member this.NextComplete : unit -> Java.Util.Concurrent.CountedCompleter

Returns

the completer, or null if none

Attributes

Remarks

If this task does not have a completer, invokes ForkJoinTask#quietlyComplete and returns null. Or, if the completer's pending count is non-zero, decrements that pending count and returns null. Otherwise, returns the completer. This method can be used as part of a completion traversal loop for homogeneous task hierarchies:

{@code
            for (CountedCompleter<?> c = firstComplete();
                 c != null;
                 c = c.nextComplete()) {
              // ... process c ...
            }}

Java documentation for java.util.concurrent.CountedCompleter.nextComplete().

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