TaskCompletionSource.SetResult Method

Definition

Transitions the underlying Task into the RanToCompletion state.

C#
public void SetResult();

Exceptions

The underlying Task is already in one of the three final states: RanToCompletion, Faulted, or Canceled.

Applies to

Proizvod Verzije
.NET 5, 6, 7, 8, 9, 10