Type.GetMethodImpl メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > Type.GetMethodImpl メソッドの意味・解説 

Type.GetMethodImpl メソッド

派生クラスによってオーバーライドされた場合指定したバインディング制約および指定した呼び出し規約使用して指定したメソッドのうち、指定した引数の型および修飾子一致するパラメータ設定されているものを検索します

名前空間: System
アセンブリ: mscorlib (mscorlib.dll 内)
構文構文

Protected MustOverride Function
 GetMethodImpl ( _
    name As String, _
    bindingAttr As BindingFlags, _
    binder As Binder, _
    callConvention As CallingConventions, _
    types As Type(), _
    modifiers As ParameterModifier() _
) As MethodInfo
Dim name As String
Dim bindingAttr As BindingFlags
Dim binder As Binder
Dim callConvention As CallingConventions
Dim types As Type()
Dim modifiers As ParameterModifier()
Dim returnValue As MethodInfo

returnValue = Me.GetMethodImpl(name, bindingAttr, binder, callConvention,
 types, modifiers)
protected abstract MethodInfo GetMethodImpl (
    string name,
    BindingFlags bindingAttr,
    Binder binder,
    CallingConventions callConvention,
    Type[] types,
    ParameterModifier[] modifiers
)
protected:
virtual MethodInfo^ GetMethodImpl (
    String^ name, 
    BindingFlags bindingAttr, 
    Binder^ binder, 
    CallingConventions callConvention, 
    array<Type^>^ types, 
    array<ParameterModifier>^ modifiers
) abstract
protected abstract MethodInfo GetMethodImpl (
    String name, 
    BindingFlags bindingAttr, 
    Binder binder, 
    CallingConventions callConvention, 
    Type[] types, 
    ParameterModifier[] modifiers
)
protected abstract function GetMethodImpl (
    name : String, 
    bindingAttr : BindingFlags, 
    binder : Binder, 
    callConvention : CallingConventions, 
    types : Type[], 
    modifiers : ParameterModifier[]
) : MethodInfo

パラメータ

name

取得するメソッドの名前を格納している String

bindingAttr

検索実行方法指定する 1 つ上の BindingFlags から成るビット マスク

または

null 参照 (Visual Basic では Nothing) を返す 0。

binder

一連のプロパティ定義しバインディング有効にする Binder オブジェクトバインディングには、オーバーロードされたメソッド選択引数の型の強制変換リフレクションによるメンバ呼び出しなどが含まれます。

または

DefaultBinder を使用する場合null 参照 (Visual Basic では Nothing)。

callConvention

引数順序レイアウト戻り値を渡す方法引数格納するレジスタスタッククリーンアップするプロセスに関する一連の規則指定する CallingConventions オブジェクト

types

取得するメソッドパラメータの数、順序、および型を表す Type オブジェクト配列

または

パラメータとらないメソッド取得するための、Type 型の空の配列 (Type[] types = new Type[0])。

または

null 参照 (Visual Basic では Nothing)。typesnull 参照 (Visual Basic では Nothing) の場合引数一致しません。

modifiers

types 配列内の対応する要素関連付けられている属性を表す ParameterModifier オブジェクト配列既定バインダは、このパラメータ処理しません。

戻り値
指定した要件一致するメソッド存在する場合は、そのメソッドを表す MethodInfo オブジェクトそれ以外場合null 参照 (Visual Basic では Nothing)。

例外例外
例外種類条件

AmbiguousMatchException

指定した名前を持ち指定したバインディング制約一致するメソッド2 つ以上存在します

ArgumentNullException

namenull 参照 (Visual Basic では Nothing) です。

ArgumentException

types多次元です。

または

modifiers多次元です。

または

typesmodifiers長さ異なります

解説解説

既定バインダParameterModifier (modifiers パラメータ) を処理しませんが、System.Reflection.Binder 抽象クラス使用してmodifiers処理するカスタム バインダ記述できますParameterModifier は、COM 相互運用機能によって呼び出すときだけに使用され参照渡しされるパラメータだけが処理されます。

typesnull 参照 (Visual Basic では Nothing) の場合引数一致しません。

types 配列modifiers 配列長さが同じです。types 配列指定するパラメータには、modifiers 配列指定されている pdIn、pdOut、pdLcid、pdRetval、pdOptional、pdHasDefault の各属性設定できます。これらの属性は、それぞれ [In]、[Out]、[lcid]、[retval]、[optional]、およびパラメータ既定値を持つかどうか指定する値を表しますパラメータ関連付けられた属性メタデータ格納され相互運用性拡張します。

次の BindingFlags フィルタ フラグは、検索対象含めメソッド定義するために使用できます

次の BindingFlags 修飾フラグは、検索方法変更するために使用できます

詳細については、「System.Reflection.BindingFlags」を参照してください

要求された型がパブリックではなく呼び出し元に現在のアセンブリ外の非パブリック オブジェクトリフレクションするための ReflectionPermission がない場合、このメソッドnull 参照 (Visual Basic では Nothing) を返します

.NET Framework のセキュリティ.NET Frameworkセキュリティ
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
Type クラス
Type メンバ
System 名前空間
MethodInfo
String クラス
BindingFlags
Binder
DefaultBinder
CallingConventions
ParameterModifier
ReflectionPermission
GetMethod
GetMethods



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

Type.GetMethodImpl メソッドのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



Type.GetMethodImpl メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2024 Microsoft.All rights reserved.

©2024 GRAS Group, Inc.RSS