Expression.GetDelegateType(Type[]) Metoda
Definicja
Ważne
Niektóre informacje odnoszą się do produktu w wersji wstępnej, który może zostać znacząco zmodyfikowany przed wydaniem. Firma Microsoft nie udziela żadnych gwarancji, jawnych lub domniemanych, w odniesieniu do informacji podanych w tym miejscu.
Type Pobiera obiekt reprezentujący typ ogólny Func<TResult> lub Action delegowany, który ma określone argumenty typu.
public:
static Type ^ GetDelegateType(... cli::array <Type ^> ^ typeArgs);
public static Type GetDelegateType(params Type[] typeArgs);
[System.Diagnostics.CodeAnalysis.RequiresDynamicCode("Delegate creation requires dynamic code generation.")]
public static Type GetDelegateType(params Type[] typeArgs);
static member GetDelegateType : Type[] -> Type
[<System.Diagnostics.CodeAnalysis.RequiresDynamicCode("Delegate creation requires dynamic code generation.")>]
static member GetDelegateType : Type[] -> Type
Public Shared Function GetDelegateType (ParamArray typeArgs As Type()) As Type
Parametry
- typeArgs
- Type[]
Argumenty typu delegata.
Zwraca
Typ delegata.
- Atrybuty
Uwagi
Ostatni argument typu określa zwracany typ delegata. Jeśli nie Func lub Action jest wystarczająco duży, wygeneruje niestandardowy typ delegata.
Podobnie jak w przypadku Func, ostatnim argumentem jest typ zwracany. Można go ustawić na System.Void wartość w celu utworzenia elementu Action.