_Type.GetMember _Type.GetMember _Type.GetMember _Type.GetMember Method

定义

为 COM 对象提供对 GetMember 方法的版本无关的访问。Provides COM objects with version-independent access to the GetMember method.

重载

GetMember(String) GetMember(String) GetMember(String) GetMember(String)

为 COM 对象提供对 GetMember(String) 方法的版本无关的访问。Provides COM objects with version-independent access to the GetMember(String) method.

GetMember(String, BindingFlags) GetMember(String, BindingFlags) GetMember(String, BindingFlags) GetMember(String, BindingFlags)

为 COM 对象提供对 GetMember(String, BindingFlags) 方法的版本无关的访问。Provides COM objects with version-independent access to the GetMember(String, BindingFlags) method.

GetMember(String, MemberTypes, BindingFlags) GetMember(String, MemberTypes, BindingFlags) GetMember(String, MemberTypes, BindingFlags) GetMember(String, MemberTypes, BindingFlags)

为 COM 对象提供对 GetMember(String, MemberTypes, BindingFlags) 方法的版本无关的访问。Provides COM objects with version-independent access to the GetMember(String, MemberTypes, BindingFlags) method.

注解

此方法用于访问托管类到从非托管代码,不应从托管代码调用。This method is for access to managed classes from unmanaged code, and should not be called from managed code.

Type.GetMember方法将获取指定的当前成员TypeThe Type.GetMember method gets the specified members of the current Type.

GetMember(String) GetMember(String) GetMember(String) GetMember(String)

为 COM 对象提供对 GetMember(String) 方法的版本无关的访问。Provides COM objects with version-independent access to the GetMember(String) method.

public:
 cli::array <System::Reflection::MemberInfo ^> ^ GetMember(System::String ^ name);
public System.Reflection.MemberInfo[] GetMember (string name);
abstract member GetMember : string -> System.Reflection.MemberInfo[]
Public Function GetMember (name As String) As MemberInfo()

参数

name
String String String String

包含要获取的公共成员名称的 StringThe String containing the name of the public members to get.

返回

一个表示具有指定名称的公共成员的 MemberInfo 对象数组(如果找到的话);否则为空数组。An array of MemberInfo objects representing the public members with the specified name, if found; otherwise, an empty array.

注解

此方法用于访问托管类到从非托管代码,不应从托管代码调用。This method is for access to managed classes from unmanaged code, and should not be called from managed code.

Type.GetMember方法搜索具有指定名称的公共成员。The Type.GetMember method searches for the public members with the specified name.

GetMember(String, BindingFlags) GetMember(String, BindingFlags) GetMember(String, BindingFlags) GetMember(String, BindingFlags)

为 COM 对象提供对 GetMember(String, BindingFlags) 方法的版本无关的访问。Provides COM objects with version-independent access to the GetMember(String, BindingFlags) method.

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

参数

name
String String String String

包含要获取的成员的名称的 StringThe String containing the name of the members to get.

bindingAttr
BindingFlags BindingFlags BindingFlags BindingFlags

一个位屏蔽,由一个或多个指定搜索执行方式的 BindingFlags 组成。A bitmask comprised of one or more BindingFlags that specify how the search is conducted.

-or- 零,返回空数组。Zero, to return an empty array.

返回

一个表示具有指定名称的公共成员的 MemberInfo 对象数组(如果找到的话);否则为空数组。An array of MemberInfo objects representing the public members with the specified name, if found; otherwise, an empty array.

注解

此方法用于访问托管类到从非托管代码,不应从托管代码调用。This method is for access to managed classes from unmanaged code, and should not be called from managed code.

Type.GetMember方法搜索指定的成员,并使用指定的绑定约束。The Type.GetMember method searches for the specified members, using the specified binding constraints.

GetMember(String, MemberTypes, BindingFlags) GetMember(String, MemberTypes, BindingFlags) GetMember(String, MemberTypes, BindingFlags) GetMember(String, MemberTypes, BindingFlags)

为 COM 对象提供对 GetMember(String, MemberTypes, BindingFlags) 方法的版本无关的访问。Provides COM objects with version-independent access to the GetMember(String, MemberTypes, BindingFlags) method.

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

参数

name
String String String String

包含要获取的成员的名称的 StringThe String containing the name of the members to get.

type
MemberTypes MemberTypes MemberTypes MemberTypes

要搜索的 MemberTypes 值。The MemberTypes value to search for.

bindingAttr
BindingFlags BindingFlags BindingFlags BindingFlags

一个位屏蔽,由一个或多个指定搜索执行方式的 BindingFlags 组成。A bitmask comprised of one or more BindingFlags that specify how the search is conducted.

-or- 零,返回空数组。Zero, to return an empty array.

返回

一个表示具有指定名称的公共成员的 MemberInfo 对象数组(如果找到的话);否则为空数组。An array of MemberInfo objects representing the public members with the specified name, if found; otherwise, an empty array.

注解

此方法用于访问托管类到从非托管代码,不应从托管代码调用。This method is for access to managed classes from unmanaged code, and should not be called from managed code.

Type.GetMember方法搜索指定的成员类型,使用指定的绑定约束的指定成员。The Type.GetMember method searches for the specified members of the specified member type, using the specified binding constraints.

适用于