RuntimeReflectionExtensions.GetRuntimeMethod(Type, String, Type[]) Metoda

Definicja

Pobiera obiekt reprezentujący określoną metodę.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Reflection::MethodInfo ^ GetRuntimeMethod(Type ^ type, System::String ^ name, cli::array <Type ^> ^ parameters);
public static System.Reflection.MethodInfo GetRuntimeMethod (this Type type, string name, Type[] parameters);
public static System.Reflection.MethodInfo? GetRuntimeMethod (this Type type, string name, Type[] parameters);
static member GetRuntimeMethod : Type * string * Type[] -> System.Reflection.MethodInfo
<Extension()>
Public Function GetRuntimeMethod (type As Type, name As String, parameters As Type()) As MethodInfo

Parametry

type
Type

Typ, który zawiera metodę .

name
String

Nazwa metody.

parameters
Type[]

Tablica zawierająca parametry metody.

Zwraca

MethodInfo

Obiekt reprezentujący określoną metodę lub null jeśli metoda nie zostanie znaleziona.

Wyjątki

type to null.

-lub-

name to null.

Znaleziono więcej niż jedną metodę o określonej nazwie.

Dotyczy

Zobacz też