BatchedJoinBlock<T1,T2>.ISourceBlock<Tuple<IList<T1>,IList<T2>>>.ReserveMessage Método

Definición

Reserva el derecho para pasar la propiedad del mensaje identificado por DataflowMessageHeader de ISourceBlock<TOutput> a ITargetBlock<TInput>.

 virtual bool System.Threading.Tasks.Dataflow.ISourceBlock<System.Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>>>.ReserveMessage(System::Threading::Tasks::Dataflow::DataflowMessageHeader messageHeader, System::Threading::Tasks::Dataflow::ITargetBlock<Tuple<System::Collections::Generic::IList<T1> ^, System::Collections::Generic::IList<T2> ^> ^> ^ target) = System::Threading::Tasks::Dataflow::ISourceBlock<Tuple<System::Collections::Generic::IList<T1> ^, System::Collections::Generic::IList<T2> ^> ^>::ReserveMessage;
bool ISourceBlock<Tuple<IList<T1>,IList<T2>>>.ReserveMessage (System.Threading.Tasks.Dataflow.DataflowMessageHeader messageHeader, System.Threading.Tasks.Dataflow.ITargetBlock<Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>>> target);
abstract member System.Threading.Tasks.Dataflow.ISourceBlock<System.Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>>>.ReserveMessage : System.Threading.Tasks.Dataflow.DataflowMessageHeader * System.Threading.Tasks.Dataflow.ITargetBlock<System.Collections.Generic.IList<'T1> * System.Collections.Generic.IList<'T2>> -> bool
override this.System.Threading.Tasks.Dataflow.ISourceBlock<System.Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>>>.ReserveMessage : System.Threading.Tasks.Dataflow.DataflowMessageHeader * System.Threading.Tasks.Dataflow.ITargetBlock<System.Collections.Generic.IList<'T1> * System.Collections.Generic.IList<'T2>> -> bool
Function ReserveMessage (messageHeader As DataflowMessageHeader, target As ITargetBlock(Of Tuple(Of IList(Of T1), IList(Of T2)))) As Boolean Implements ISourceBlock(Of Tuple(Of IList(Of T1), IList(Of T2))).ReserveMessage

Parámetros

messageHeader
DataflowMessageHeader

DataflowMessageHeader del mensaje que se va a reservar.

target
ITargetBlock<Tuple<IList<T1>,IList<T2>>>

ITargetBlock<TInput> para el que se va a reservar el mensaje.

Devoluciones

true si se ha procesado correctamente el mensaje; de lo contrario, es false.

Implementaciones

Excepciones

messageHeader no es válido.

target es null (Nothing en Visual Basic).

Comentarios

El ITargetBlock<TInput> para el que se va a reservar el mensaje no debe estar vinculado desde esta ISourceBlock<TOutput> instancia. Además, es posible que esta ISourceBlock<TOutput> instancia nunca haya ofrecido el mensaje directamente a .ITargetBlock<TInput>

Si true se devuelve , debe llamar ConsumeMessage posteriormente a o ReleaseReservation para este mensaje con los mismos DataflowMessageHeader y ITargetBlock<TInput>. Si no lo hace, es posible que el origen no pueda propagar ningún mensaje adicional a ningún destino.

No llames ReserveMessage mientras el destino contiene bloqueos internos. Si lo hace, se infringirá la jerarquía de bloqueos necesaria para evitar interbloqueos en una red de flujo de datos.

Se aplica a