このプロパティのパブリックな get アクセサを返します。
Overloads Public Function GetGetMethod() As MethodInfo
[C#]
public MethodInfo GetGetMethod();
[C++]
public: MethodInfo* GetGetMethod();
[JScript]
public function GetGetMethod() : MethodInfo;
戻り値
このプロパティのパブリックな get アクセサを表す MethodInfo オブジェクト。get アクセサが非パブリックまたは存在しない場合は null 参照 (Visual Basic では Nothing) 。
解説
このメソッドは、 nonPublic パラメータに false を設定した GetGetMethod 抽象メソッドの実装を提供する便宜的なメソッドです。
GetGetMethod メソッドを使用するには、最初に Type クラスを取得します。そして、その Type から PropertyInfo を取得します。最後に PropertyInfo から、 GetGetMethod メソッドを使用します。
必要条件
プラットフォーム: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 ファミリ, .NET Compact Framework - Windows CE .NET, Common Language Infrastructure (CLI) Standard
.NET Framework セキュリティ:
- ReflectionPermission (Type.InvokeMember などの機構を通じて遅延バインディングで呼び出すときに必要なアクセス許可) ReflectionPermissionFlag.MemberAccess (関連する列挙体)
参照
PropertyInfo クラス | PropertyInfo メンバ | System.Reflection 名前空間 | PropertyInfo.GetGetMethod オーバーロードの一覧