Expression.GetDelegateType(Type[]) Metoda

Definicja

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);
static member GetDelegateType : Type[] -> Type
Public Shared Function GetDelegateType (ParamArray typeArgs As Type()) As Type

Parametry

typeArgs
Type[]

Argumenty typu delegata.

Zwraca

Typ delegata.

Uwagi

Ostatni argument typu określa zwracany typ delegata. Jeśli nie Func lub Action jest wystarczająco duży, zostanie wygenerowany niestandardowy typ delegata.

Podobnie jak w przypadku Func, ostatnim argumentem jest zwracany typ. Można go ustawić na System.Void wartość w celu utworzenia elementu Action.

Dotyczy