Export (0) Print
Expand All

JoinBlock<T1, T2, T3>.ISourceBlock<Tuple<T1, T2, T3>>.ConsumeMessage Method

.NET Framework 4.5

Called by a linked ITargetBlock<TInput> to accept and consume a DataflowMessageHeader previously offered by this ISourceBlock<TOutput>.

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

Tuple<T1, T2, T3> ISourceBlock<Tuple<T1, T2, T3>>.ConsumeMessage(
	DataflowMessageHeader messageHeader,
	ITargetBlock<Tuple<T1, T2, T3>> target,
	out bool messageConsumed


Type: System.Threading.Tasks.Dataflow.DataflowMessageHeader

The DataflowMessageHeader of the message being consumed.

Type: System.Threading.Tasks.Dataflow.ITargetBlock<Tuple<T1, T2, T3>>

The ITargetBlock<TInput> consuming the message.

Type: System.Boolean

true if the message was successfully consumed; otherwise, false.

Return Value

Type: System.Tuple<T1, T2, T3>
The value of the consumed message. This may correspond to a different DataflowMessageHeader instance than was previously reserved and passed as the messageHeader to ConsumeMessage. The consuming ITargetBlock<TInput> must use the returned value instead of the value passed as messageValue through OfferMessage.
If the message requested is not available, the return value will be null.


ISourceBlock<TOutput>.ConsumeMessage(DataflowMessageHeader, ITargetBlock<TOutput>, Boolean)


The messageHeader is not valid.


The target is null.

Only ITargetBlock<TInput> instances linked to this ISourceBlock<TOutput> instance may use ConsumeMessage, and it must only be used to consume DataflowMessageHeader instances previously offered by this source to the target.

.NET Framework

Supported in: 4.5

Portable Class Library

Supported in: Portable Class Library

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

© 2014 Microsoft