MemberDescriptor.FindMethod Metoda

Definice

Vyhledá danou metodu prostřednictvím reflexe.

Přetížení

FindMethod(Type, String, Type[], Type)

Vyhledá danou metodu prostřednictvím reflexe a vyhledá pouze veřejné metody.

FindMethod(Type, String, Type[], Type, Boolean)

Vyhledá danou metodu prostřednictvím reflexe s možností prohledávat pouze veřejné metody.

FindMethod(Type, String, Type[], Type)

Zdroj:
MemberDescriptor.cs
Zdroj:
MemberDescriptor.cs
Zdroj:
MemberDescriptor.cs

Vyhledá danou metodu prostřednictvím reflexe a vyhledá pouze veřejné metody.

protected:
 static System::Reflection::MethodInfo ^ FindMethod(Type ^ componentClass, System::String ^ name, cli::array <Type ^> ^ args, Type ^ returnType);
protected static System.Reflection.MethodInfo FindMethod (Type componentClass, string name, Type[] args, Type returnType);
protected static System.Reflection.MethodInfo? FindMethod (Type componentClass, string name, Type[] args, Type returnType);
static member FindMethod : Type * string * Type[] * Type -> System.Reflection.MethodInfo
Protected Shared Function FindMethod (componentClass As Type, name As String, args As Type(), returnType As Type) As MethodInfo

Parametry

componentClass
Type

Komponenta, která obsahuje metodu .

name
String

Název metody, která se má najít.

args
Type[]

Pole parametrů pro metodu, které slouží k výběru mezi přetíženými metodami.

returnType
Type

Typ, který se má vrátit pro metodu .

Návraty

A MethodInfo , který představuje metodu, nebo null pokud metoda nebyla nalezena.

Platí pro

FindMethod(Type, String, Type[], Type, Boolean)

Zdroj:
MemberDescriptor.cs
Zdroj:
MemberDescriptor.cs
Zdroj:
MemberDescriptor.cs

Vyhledá danou metodu prostřednictvím reflexe s možností prohledávat pouze veřejné metody.

protected:
 static System::Reflection::MethodInfo ^ FindMethod(Type ^ componentClass, System::String ^ name, cli::array <Type ^> ^ args, Type ^ returnType, bool publicOnly);
protected static System.Reflection.MethodInfo FindMethod (Type componentClass, string name, Type[] args, Type returnType, bool publicOnly);
protected static System.Reflection.MethodInfo? FindMethod (Type componentClass, string name, Type[] args, Type returnType, bool publicOnly);
static member FindMethod : Type * string * Type[] * Type * bool -> System.Reflection.MethodInfo
Protected Shared Function FindMethod (componentClass As Type, name As String, args As Type(), returnType As Type, publicOnly As Boolean) As MethodInfo

Parametry

componentClass
Type

Komponenta, která obsahuje metodu .

name
String

Název metody, která se má najít.

args
Type[]

Pole parametrů pro metodu, které slouží k výběru mezi přetíženými metodami.

returnType
Type

Typ, který se má vrátit pro metodu .

publicOnly
Boolean

Určuje, jestli se má vyhledávání omezit na veřejné metody.

Návraty

A MethodInfo , který představuje metodu, nebo null pokud metoda nebyla nalezena.

Platí pro