Partilhar via


BatchedJoinBlock<T1,T2,T3>.TryReceive Método

Definição

Tentativas de receber assincronamente um item de saída disponível do IReceivableSourceBlock<TOutput>.

public:
 virtual bool TryReceive(Predicate<Tuple<System::Collections::Generic::IList<T1> ^, System::Collections::Generic::IList<T2> ^, System::Collections::Generic::IList<T3> ^> ^> ^ filter, [Runtime::InteropServices::Out] Tuple<System::Collections::Generic::IList<T1> ^, System::Collections::Generic::IList<T2> ^, System::Collections::Generic::IList<T3> ^> ^ % item);
public bool TryReceive (Predicate<Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>,System.Collections.Generic.IList<T3>>> filter, out Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>,System.Collections.Generic.IList<T3>> item);
public bool TryReceive (Predicate<Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>,System.Collections.Generic.IList<T3>>>? filter, out Tuple<System.Collections.Generic.IList<T1>,System.Collections.Generic.IList<T2>,System.Collections.Generic.IList<T3>>? item);
abstract member TryReceive : Predicate<System.Collections.Generic.IList<'T1> * System.Collections.Generic.IList<'T2> * System.Collections.Generic.IList<'T3>> * Tuple -> bool
override this.TryReceive : Predicate<System.Collections.Generic.IList<'T1> * System.Collections.Generic.IList<'T2> * System.Collections.Generic.IList<'T3>> * Tuple -> bool
Public Function TryReceive (filter As Predicate(Of Tuple(Of IList(Of T1), IList(Of T2), IList(Of T3))), ByRef item As Tuple(Of IList(Of T1), IList(Of T2), IList(Of T3))) As Boolean

Parâmetros

filter
Predicate<Tuple<IList<T1>,IList<T2>,IList<T3>>>

O predicado que um valor precisa passar com êxito para ser recebido. filter pode ser null, caso em que todos os itens passarão.

item
Tuple<IList<T1>,IList<T2>,IList<T3>>

O item recebido da origem.

Retornos

Boolean

true se foi possível receber um item; caso contrário, false.

Comentários

Esse método não bloqueia a espera para que a origem forneça um item.

Ele retornará após a verificação de um elemento, se um elemento estava disponível ou não.

Aplica-se a