StackFrame.GetMember(String, BindingFlags) 方法

定义

检索 MemberInfo 对象的数组,这些对象对应于与指定名称匹配的所有成员。Retrieves an array of MemberInfo objects that correspond to all members that match a specified name.

此 API 支持产品基础结构,不能在代码中直接使用。

public:
 override cli::array <System::Reflection::MemberInfo ^> ^ GetMember(System::String ^ name, System::Reflection::BindingFlags bindingAttr);
public override System.Reflection.MemberInfo[] GetMember (string name, System.Reflection.BindingFlags bindingAttr);
override this.GetMember : string * System.Reflection.BindingFlags -> System.Reflection.MemberInfo[]
Public Overrides Function GetMember (name As String, bindingAttr As BindingFlags) As MemberInfo()

参数

name
String

要搜索的成员名称。The member name to search for.

bindingAttr
BindingFlags

枚举值的按位组合,用于指定反射如何执行成员搜索。A bitwise combination of the enumeration values that specifies how the search for members is conducted by reflection.

返回

MemberInfo[]

name 参数匹配的对象的数组。An array of objects that match the name argument.

适用于

另请参阅