TypeBuilder.DefinePInvokeMethodCore メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
派生クラスでオーバーライドされた場合、指定された名前、DLL 名、エントリ ポイント名、属性、呼び出し規約、戻り値の型、パラメーターの型、PInvoke フラグ、およびパラメーターと戻り値の型のカスタム修飾子を使用して PInvoke メソッドを定義します。
protected:
abstract System::Reflection::Emit::MethodBuilder ^ DefinePInvokeMethodCore(System::String ^ name, System::String ^ dllName, System::String ^ entryName, System::Reflection::MethodAttributes attributes, System::Reflection::CallingConventions callingConvention, Type ^ returnType, cli::array <Type ^> ^ returnTypeRequiredCustomModifiers, cli::array <Type ^> ^ returnTypeOptionalCustomModifiers, cli::array <Type ^> ^ parameterTypes, cli::array <cli::array <Type ^> ^> ^ parameterTypeRequiredCustomModifiers, cli::array <cli::array <Type ^> ^> ^ parameterTypeOptionalCustomModifiers, System::Runtime::InteropServices::CallingConvention nativeCallConv, System::Runtime::InteropServices::CharSet nativeCharSet);
protected abstract System.Reflection.Emit.MethodBuilder DefinePInvokeMethodCore (string name, string dllName, string entryName, System.Reflection.MethodAttributes attributes, System.Reflection.CallingConventions callingConvention, Type? returnType, Type[]? returnTypeRequiredCustomModifiers, Type[]? returnTypeOptionalCustomModifiers, Type[]? parameterTypes, Type[][]? parameterTypeRequiredCustomModifiers, Type[][]? parameterTypeOptionalCustomModifiers, System.Runtime.InteropServices.CallingConvention nativeCallConv, System.Runtime.InteropServices.CharSet nativeCharSet);
abstract member DefinePInvokeMethodCore : string * string * string * System.Reflection.MethodAttributes * System.Reflection.CallingConventions * Type * Type[] * Type[] * Type[] * Type[][] * Type[][] * System.Runtime.InteropServices.CallingConvention * System.Runtime.InteropServices.CharSet -> System.Reflection.Emit.MethodBuilder
Protected MustOverride Function DefinePInvokeMethodCore (name As String, dllName As String, entryName As String, attributes As MethodAttributes, callingConvention As CallingConventions, returnType As Type, returnTypeRequiredCustomModifiers As Type(), returnTypeOptionalCustomModifiers As Type(), parameterTypes As Type(), parameterTypeRequiredCustomModifiers As Type()(), parameterTypeOptionalCustomModifiers As Type()(), nativeCallConv As CallingConvention, nativeCharSet As CharSet) As MethodBuilder
パラメーター
- name
- String
PInvoke
メソッドの名前。
name
に埋め込み null 値を含めることはできません。
- dllName
- String
PInvoke
メソッドが定義されている DLL の名前。
- entryName
- String
DLL 内のエントリ ポイントの名前。
- attributes
- MethodAttributes
メソッドの属性を指定する列挙値のビットごとの組み合わせ。
- callingConvention
- CallingConventions
メソッドの呼び出し規則。
- returnType
- Type
メソッドの戻り値の型。
- returnTypeRequiredCustomModifiers
- Type[]
必要なカスタム修飾子を表す型の配列
- returnTypeOptionalCustomModifiers
- Type[]
省略可能なカスタム修飾子を表す型の配列
- parameterTypes
- Type[]
メソッドのパラメーター型。
- parameterTypeRequiredCustomModifiers
- Type[][]
型の配列の配列。 型の各配列は、対応するパラメーターに必要なカスタム修飾子を表します。
- parameterTypeOptionalCustomModifiers
- Type[][]
型の配列の配列。 型の各配列は、対応するパラメーターのオプションのカスタム修飾子を表します。
- nativeCallConv
- CallingConvention
ネイティブ呼び出し規則。
- nativeCharSet
- CharSet
メソッドのネイティブ文字セット。
戻り値
定義された PInvoke
メソッドを表す MethodBuilder。
適用対象
GitHub で Microsoft と共同作業する
このコンテンツのソースは GitHub にあります。そこで、issue や pull request を作成および確認することもできます。 詳細については、共同作成者ガイドを参照してください。
.NET