DataflowBlock::OutputAvailableAsync<TOutput> Method (ISourceBlock<TOutput>^, CancellationToken)
Provides a Task<TResult> that asynchronously monitors the source for available output.
Assembly: System.Threading.Tasks.Dataflow (in System.Threading.Tasks.Dataflow.dll)
public: generic<typename TOutput> [ExtensionAttribute] static Task<bool>^ OutputAvailableAsync( ISourceBlock<TOutput>^ source, CancellationToken cancellationToken )
Parameters
- source
-
Type:
System.Threading.Tasks.Dataflow::ISourceBlock<TOutput>^
The source to monitor.
- cancellationToken
-
Type:
System.Threading::CancellationToken
The cancellation token with which to cancel the asynchronous operation.
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. If it returns false, more output is not and will never be available, due to the source completing prior to output being available.
Type Parameters
- TOutput
Specifies the type of data contained in the source.
Show: