Delegate.EnumerateInvocationList<TDelegate>(TDelegate) Metodo

Definizione

Ottiene un enumeratore per le destinazioni di chiamata di questo delegato.

public:
generic <typename TDelegate>
 where TDelegate : Delegate static Delegate::InvocationListEnumerator<TDelegate> EnumerateInvocationList(TDelegate d);
public static Delegate.InvocationListEnumerator<TDelegate> EnumerateInvocationList<TDelegate>(TDelegate? d) where TDelegate : Delegate;
static member EnumerateInvocationList : 'Delegate -> Delegate.InvocationListEnumerator<'Delegate (requires 'Delegate :> Delegate)> (requires 'Delegate :> Delegate)
Public Shared Function EnumerateInvocationList(Of TDelegate As Delegate) (d As TDelegate) As Delegate.InvocationListEnumerator(Of TDelegate)

Parametri di tipo

TDelegate

Tipo delegato da enumerare.

Parametri

d
TDelegate

Delegato da enumerare.

Valori restituiti

Oggetto Delegate.InvocationListEnumerator<TDelegate> che segue il modello IEnumerable e quindi può essere usato in un'istruzione "foreach" C# per recuperare le destinazioni di chiamata di questo delegato senza allocazioni. Il metodo restituisce un enumeratore vuoto per null il delegato.

Commenti

L'ordine dei delegati restituiti dall'enumeratore è lo stesso ordine in cui il delegato corrente richiama i metodi rappresentati da tali delegati.

Si applica a