PropertyBuilder.GetGetMethod(Boolean) メソッド

定義

このプロパティのパブリックおよび非パブリックな get アクセサーを返します。

public:
 override System::Reflection::MethodInfo ^ GetGetMethod(bool nonPublic);
public override System.Reflection.MethodInfo? GetGetMethod (bool nonPublic);
public override System.Reflection.MethodInfo GetGetMethod (bool nonPublic);
override this.GetGetMethod : bool -> System.Reflection.MethodInfo
Public Overrides Function GetGetMethod (nonPublic As Boolean) As MethodInfo

パラメーター

nonPublic
Boolean

非パブリックな get アクセサーを返すかどうかを示します。 非パブリック メソッドが含まれる場合は true。それ以外の場合は false

戻り値

nonPublicMethodInfo の場合は、このプロパティの get アクセサーを表す true オブジェクト。 nonPublicnull で get アクセサーが非パブリックの場合、または nonPublicfalse でも get アクセサーがない場合は、true を返します。

注釈

プロパティの getter を取得するには、Type.GetType または Assembly.GetType を使用してプロパティの親型を反映し、その型から Reflection プロパティ オブジェクトを取得し、PropertyInfo.GetGetMethod を呼び出します。

適用対象