Show / Hide Table of Contents

Class TaskCompletionPipe

Provides various extension methods for TaskCompletionPipe<T> class.

Inheritance
object
TaskCompletionPipe
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: DotNext.Threading.Tasks
Assembly: DotNext.Threading.dll
Syntax
public static class TaskCompletionPipe

Methods

| Edit this page View Source

Consume<T>(TaskCompletionPipe<Task<T>>)

Gets asynchronous consumer.

Declaration
public static TaskCompletionPipe.Consumer<T> Consume<T>(this TaskCompletionPipe<Task<T>> pipe)
Parameters
Type Name Description
TaskCompletionPipe<Task<T>> pipe

The task completion pipe with typed tasks.

Returns
Type Description
TaskCompletionPipe.Consumer<T>

The asynchronous consuming collection.

Type Parameters
Name Description
T

The type of the elements in the consuming collection.

| Edit this page View Source

Consume<T>(ReadOnlySpan<Task<T>>)

Gets a collection over tasks to be available as they complete.

Declaration
public static TaskCompletionPipe.Consumer<T> Consume<T>(this ReadOnlySpan<Task<T>> tasks)
Parameters
Type Name Description
ReadOnlySpan<Task<T>> tasks

A collection of tasks.

Returns
Type Description
TaskCompletionPipe.Consumer<T>

A collection over task results to be available as they complete.

Type Parameters
Name Description
T

The result type of tasks.

| Edit this page View Source

WhenEach<T>(ReadOnlySpan<T>)

Creates a collection over tasks to be available as they complete.

Declaration
public static IAsyncEnumerable<T> WhenEach<T>(ReadOnlySpan<T> tasks) where T : Task
Parameters
Type Name Description
ReadOnlySpan<T> tasks

A collection of tasks.

Returns
Type Description
IAsyncEnumerable<T>

A collection over tasks to be available as they complete.

Type Parameters
Name Description
T

The type of tasks.

  • Edit this page
  • View Source
☀
☾
In this article
Back to top
Supported by the .NET Foundation
☀
☾