TypeInfo.GetDeclaredMethods(String) 方法

定义

返回包含所有与指定名称相匹配在当前类型声明的公共方法的集合。Returns a collection that contains all public methods declared on the current type that match the specified name.

public:
 virtual System::Collections::Generic::IEnumerable<System::Reflection::MethodInfo ^> ^ GetDeclaredMethods(System::String ^ name);
public virtual System.Collections.Generic.IEnumerable<System.Reflection.MethodInfo> GetDeclaredMethods (string name);
abstract member GetDeclaredMethods : string -> seq<System.Reflection.MethodInfo>
override this.GetDeclaredMethods : string -> seq<System.Reflection.MethodInfo>
Public Iterator Overridable Function GetDeclaredMethods (name As String) As IEnumerable(Of MethodInfo)

参数

name
String

要搜索的方法名称。The method name to search for.

返回

包含匹配 name的方法的集合。A collection that contains methods that match name.

异常

namenullname is null.

适用于