FieldInfo.IsPinvokeImplとは? わかりやすく解説

FieldInfo.IsPinvokeImpl プロパティ

対応する PinvokeImpl 属性が FieldAttributes に設定されているかどうかを示す値を取得します

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

Dim instance As FieldInfo
Dim value As Boolean

value = instance.IsPinvokeImpl
public bool IsPinvokeImpl { get;
 }
/** @property */
public final boolean get_IsPinvokeImpl ()

プロパティ
FieldAttributesPinvokeImpl 属性設定されている場合trueそれ以外場合false

使用例使用例

クラス作成し、名前、フィールドフィールドIsPinvokeImpl プロパティの値を表示する例を次に示します

Imports System
Imports System.Reflection
Imports Microsoft.VisualBasic

Public Class Fieldinfo_IsPinvoke
    Public myField As String
 = "A public field"

    Public Shared Sub Main()
        Dim myObject As New
 Fieldinfo_IsPinvoke()

        ' Get the Type and FieldInfo.
        Dim myType1 As Type = GetType(Fieldinfo_IsPinvoke)
        Dim myFieldInfo As FieldInfo = myType1.GetField("myField",
 _
           BindingFlags.Public Or BindingFlags.Instance)

        ' Display the name, field and the PInvokeImpl attribute for
 the field.
        Console.Write(ControlChars.NewLine & "Name of class:
 {0}", _
                                         myType1.FullName)
        Console.Write(ControlChars.NewLine & "Value of field:
 {0}", _
                                         myFieldInfo.GetValue(myObject))
        Console.Write(ControlChars.NewLine & "IsPinvokeImpl:
 {0}", _
                                         myFieldInfo.IsPinvokeImpl)
    End Sub
End Class
using System;
using System.Reflection;

public class Fieldinfo_IsPinvoke
{
    public string myField = "A public
 field";
   
    public static void Main()
    {
        Fieldinfo_IsPinvoke myObject = new Fieldinfo_IsPinvoke();
      
        // Get the Type and FieldInfo.
        Type myType1 = typeof(Fieldinfo_IsPinvoke);
        FieldInfo myFieldInfo = myType1.GetField("myField",
            BindingFlags.Public|BindingFlags.Instance);

        // Display the name, field and the PInvokeImpl attribute for
 the field.
        Console.Write("\n Name of class: {0}", myType1.FullName);
        Console.Write("\n Value of field: {0}", myFieldInfo.GetValue(myObject));
        Console.Write("\n IsPinvokeImpl: {0}", 
            myFieldInfo.IsPinvokeImpl );
    }
}
using namespace System;
using namespace System::Reflection;

public ref class Fieldinfo_IsPinvoke
{
public:
   String^ myField;
   Fieldinfo_IsPinvoke()
   {
      myField = "A public field";
   }
};

int main()
{
   Fieldinfo_IsPinvoke^ myObject = gcnew Fieldinfo_IsPinvoke;

   // Get the Type and FieldInfo.
   Type^ myType1 = Fieldinfo_IsPinvoke::typeid;
   FieldInfo^ myFieldInfo = myType1->GetField( "myField", static_cast<BindingFlags>(BindingFlags::Public
 | BindingFlags::Instance) );

   // Display the name, field and the PInvokeImpl attribute for the
 field.
   Console::Write( "\n Name of class: {0}", myType1->FullName
 );
   Console::Write( "\n Value of field: {0}", myFieldInfo->GetValue(
 myObject ) );
   Console::Write( "\n IsPinvokeImpl: {0}", myFieldInfo->IsPinvokeImpl
 );
}
import System.*;
import System.Reflection.*;

public class FieldInfoIsPinvoke
{
    public String myField = "A public
 field";

    public static void main(String[]
 args)
    {
        FieldInfoIsPinvoke myObject = new FieldInfoIsPinvoke();

        // Get the Type and FieldInfo.
        Type myType1 = FieldInfoIsPinvoke.class.ToType();
        FieldInfo myFieldInfo = myType1.GetField("myField", BindingFlags.Public
            | BindingFlags.Instance);

        // Display the name, field and the PInvokeImpl attribute for
 the field.
        Console.Write("\n Name of class: {0}", myType1.get_FullName());
        Console.Write("\n Value of field: {0}", 
            myFieldInfo.GetValue(myObject));
        Console.Write("\n IsPinvokeImpl: {0}", 
            (System.Boolean)myFieldInfo.get_IsPinvokeImpl());
    } //main
} //FieldInfoIsPinvoke
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

_FieldInfo.IsPinvokeImpl プロパティ

メモ : このプロパティは、.NET Framework version 2.0新しく追加されたものです。

COM オブジェクトに、IsPinvokeImpl プロパティへのバージョン依存しないアクセス用意されています。

このプロパティは、CLS準拠していません。  

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

Dim instance As _FieldInfo
Dim value As Boolean

value = instance.IsPinvokeImpl
bool IsPinvokeImpl { get; }
property bool IsPinvokeImpl {
    bool get ();
}
/** @property */
boolean get_IsPinvokeImpl ()
function get IsPinvokeImpl () : boolean

プロパティ
FieldAttributes に PinvokeImpl 属性設定されている場合trueそれ以外場合false

解説解説

このプロパティは、アンマネージ コードからマネージ クラスアクセスするためのプロパティであるため、マネージ コードからは呼び出さないください

IsPinvokeImpl プロパティは、対応する PinvokeImpl 属性FieldAttributes設定されているかどうかを示す値を取得します

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
_FieldInfo インターフェイス
_FieldInfo メンバ
System.Runtime.InteropServices 名前空間


このページでは「.NET Framework クラス ライブラリ リファレンス」からFieldInfo.IsPinvokeImplを検索した結果を表示しています。
Weblioに収録されているすべての辞書からFieldInfo.IsPinvokeImplを検索する場合は、下記のリンクをクリックしてください。
 全ての辞書からFieldInfo.IsPinvokeImpl を検索

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

辞書ショートカット

すべての辞書の索引

FieldInfo.IsPinvokeImplのお隣キーワード
検索ランキング

   

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



FieldInfo.IsPinvokeImplのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

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

©2025 GRAS Group, Inc.RSS