CompletableFuture.MinimalCompletionStage Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns a new CompletionStage that is completed normally with
the same value as this CompletableFuture when it completes
normally, and cannot be independently completed or otherwise
used in ways not defined by the methods of interface CompletionStage
.
[Android.Runtime.Register("minimalCompletionStage", "()Ljava/util/concurrent/CompletionStage;", "GetMinimalCompletionStageHandler", ApiSince=31)]
public virtual Java.Util.Concurrent.ICompletionStage? MinimalCompletionStage ();
[<Android.Runtime.Register("minimalCompletionStage", "()Ljava/util/concurrent/CompletionStage;", "GetMinimalCompletionStageHandler", ApiSince=31)>]
abstract member MinimalCompletionStage : unit -> Java.Util.Concurrent.ICompletionStage
override this.MinimalCompletionStage : unit -> Java.Util.Concurrent.ICompletionStage
Returns
the new CompletionStage
- Attributes
Remarks
Returns a new CompletionStage that is completed normally with the same value as this CompletableFuture when it completes normally, and cannot be independently completed or otherwise used in ways not defined by the methods of interface CompletionStage
. If this CompletableFuture completes exceptionally, then the returned CompletionStage completes exceptionally with a CompletionException with this exception as cause.
Unless overridden by a subclass, a new non-minimal CompletableFuture with all methods available can be obtained from a minimal CompletionStage via #toCompletableFuture()
. For example, completion of a minimal stage can be awaited by
{@code minimalStage.toCompletableFuture().join(); }
Added in 9.
Java documentation for java.util.concurrent.CompletableFuture.minimalCompletionStage()
.
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.