Expression.GetFuncType(Type[]) メソッド

定義

特定の型引数を持つジェネリック Type デリゲート型を表すFunc<TResult> オブジェクトを作成します。 最後の型引数は、作成されたデリゲートの戻り値の型を指定します。

public:
 static Type ^ GetFuncType(... cli::array <Type ^> ^ typeArgs);
public static Type GetFuncType(params Type[] typeArgs);
[System.Diagnostics.CodeAnalysis.RequiresDynamicCode("Delegate creation requires dynamic code generation.")]
public static Type GetFuncType(params Type[]? typeArgs);
public static Type GetFuncType(params Type[]? typeArgs);
static member GetFuncType : Type[] -> Type
[<System.Diagnostics.CodeAnalysis.RequiresDynamicCode("Delegate creation requires dynamic code generation.")>]
static member GetFuncType : Type[] -> Type
Public Shared Function GetFuncType (ParamArray typeArgs As Type()) As Type

パラメーター

typeArgs
Type[]

Typeデリゲート型の型引数を指定する 1 から 17 個のSystem.Func オブジェクトの配列。

返品

指定した型引数を持つ Func<TResult> デリゲートの型。

属性

例外

typeArgs には、1 つ以上の 17 個の要素が含まれています。

typeArgsnullです。

注釈

typeArgs には、1 つ以上の要素と最大 17 個の要素が含まれている必要があります。

たとえば、typeArgs の要素が型 T1…Tn を表す場合、結果の Type オブジェクトは、C# で構築されたデリゲート型 System.Func<T1,…,Tn> を表し、Visual Basic では System.Func(Of T1,…,Tn) を表します。

適用対象