DataflowBlock.OutputAvailableAsync<TOutput> Method (ISourceBlock<TOutput>)

.NET Framework (current version)

Provides a Task<TResult> that asynchronously monitors the source for available output.

Namespace:  System.Threading.Tasks.Dataflow
Assembly:  System.Threading.Tasks.Dataflow (in System.Threading.Tasks.Dataflow.dll)

public static Task<bool> OutputAvailableAsync<TOutput>(
	this ISourceBlock<TOutput> source

Type Parameters


Specifies the type of data contained in the source.


Type: System.Threading.Tasks.Dataflow.ISourceBlock<TOutput>

The source to monitor.

Return Value

Type: System.Threading.Tasks.Task<Boolean>
A Task<TResult> that informs of whether and when more output is available. If, when the task completes, its Result is true, more output is available in the source (though another consumer of the source may retrieve the data).
If it returns false, more output is not and will never be available, due to the source completing prior to output being available.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type ISourceBlock<TOutput>. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

.NET Framework

Supported in: 4.5

Portable Class Library

Supported in: Portable Class Library