ISourceBlock(Of TOutput).ReleaseReservation Method

.NET Framework (current version)

Called by a linked ITargetBlock(Of TInput) to release a previously reserved DataflowMessageHeader by this ISourceBlock(Of TOutput).

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

'Declaration
Sub ReleaseReservation ( _
	messageHeader As DataflowMessageHeader, _
	target As ITargetBlock(Of TOutput) _
)

Parameters

messageHeader
Type: System.Threading.Tasks.Dataflow.DataflowMessageHeader

The DataflowMessageHeader of the reserved message being released.

target
Type: System.Threading.Tasks.Dataflow.ITargetBlock(Of TOutput)

The ITargetBlock(Of TInput) releasing the message it previously reserved.

ExceptionCondition
ArgumentException

The messageHeader is not valid.

ArgumentNullException

The target is Nothing.

InvalidOperationException

The target did not have the message reserved.

Only ITargetBlock(Of TInput) instances linked to this ISourceBlock(Of TOutput) instance may use ReleaseReservation, and it must only be used to release DataflowMessageHeader instances previously and successfully reserved by the target.

.NET Framework

Supported in: 4.5

Portable Class Library

Supported in: Portable Class Library
Show: