ModuleBuilder クラス

定義

動的アセンブリ内のモジュールを定義して表します。

public ref class ModuleBuilder : System::Reflection::Module
public ref class ModuleBuilder abstract : System::Reflection::Module
public ref class ModuleBuilder : System::Reflection::Module, System::Runtime::InteropServices::_ModuleBuilder
public class ModuleBuilder : System.Reflection.Module
public abstract class ModuleBuilder : System.Reflection.Module
[System.Runtime.InteropServices.ClassInterface(System.Runtime.InteropServices.ClassInterfaceType.None)]
public class ModuleBuilder : System.Reflection.Module, System.Runtime.InteropServices._ModuleBuilder
[System.Runtime.InteropServices.ClassInterface(System.Runtime.InteropServices.ClassInterfaceType.None)]
[System.Runtime.InteropServices.ComVisible(true)]
public class ModuleBuilder : System.Reflection.Module, System.Runtime.InteropServices._ModuleBuilder
type ModuleBuilder = class
    inherit Module
[<System.Runtime.InteropServices.ClassInterface(System.Runtime.InteropServices.ClassInterfaceType.None)>]
type ModuleBuilder = class
    inherit Module
    interface _ModuleBuilder
[<System.Runtime.InteropServices.ClassInterface(System.Runtime.InteropServices.ClassInterfaceType.None)>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type ModuleBuilder = class
    inherit Module
    interface _ModuleBuilder
Public Class ModuleBuilder
Inherits Module
Public MustInherit Class ModuleBuilder
Inherits Module
Public Class ModuleBuilder
Inherits Module
Implements _ModuleBuilder
継承
ModuleBuilder
属性
実装

次のコード サンプルは、ModuleBuilder を使用して動的モジュールを作成する方法を示しています。 ModuleBuilder は、コンストラクターではなく、AssemblyBuilderDefineDynamicModule を呼び出すことによって作成されることに注意してください。

using namespace System;
using namespace System::Reflection;
using namespace System::Reflection::Emit;
public ref class CodeGenerator
{
private:
   AssemblyBuilder^ myAssemblyBuilder;

public:
   CodeGenerator()
   {
      // Get the current application domain for the current thread.
      AppDomain^ myCurrentDomain = AppDomain::CurrentDomain;
      AssemblyName^ myAssemblyName = gcnew AssemblyName;
      myAssemblyName->Name = "TempAssembly";

      // Define a dynamic assembly in the current application domain.
      myAssemblyBuilder = myCurrentDomain->DefineDynamicAssembly( myAssemblyName, AssemblyBuilderAccess::Run );

      // Define a dynamic module in this assembly.
      ModuleBuilder^ myModuleBuilder = myAssemblyBuilder->DefineDynamicModule( "TempModule" );

      // Define a runtime class with specified name and attributes.
      TypeBuilder^ myTypeBuilder = myModuleBuilder->DefineType( "TempClass", TypeAttributes::Public );

      // Add 'Greeting' field to the class, with the specified attribute and type.
      FieldBuilder^ greetingField = myTypeBuilder->DefineField( "Greeting", String::typeid, FieldAttributes::Public );
      array<Type^>^myMethodArgs = {String::typeid};

      // Add 'MyMethod' method to the class, with the specified attribute and signature.
      MethodBuilder^ myMethod = myTypeBuilder->DefineMethod( "MyMethod", MethodAttributes::Public, CallingConventions::Standard, nullptr, myMethodArgs );
      ILGenerator^ methodIL = myMethod->GetILGenerator();
      methodIL->EmitWriteLine( "In the method..." );
      methodIL->Emit( OpCodes::Ldarg_0 );
      methodIL->Emit( OpCodes::Ldarg_1 );
      methodIL->Emit( OpCodes::Stfld, greetingField );
      methodIL->Emit( OpCodes::Ret );
      myTypeBuilder->CreateType();
   }

   property AssemblyBuilder^ MyAssembly 
   {
      AssemblyBuilder^ get()
      {
         return this->myAssemblyBuilder;
      }
   }
};

int main()
{
   CodeGenerator^ myCodeGenerator = gcnew CodeGenerator;

   // Get the assembly builder for 'myCodeGenerator' object.
   AssemblyBuilder^ myAssemblyBuilder = myCodeGenerator->MyAssembly;

   // Get the module builder for the above assembly builder object .
   ModuleBuilder^ myModuleBuilder = myAssemblyBuilder->GetDynamicModule( "TempModule" );
   Console::WriteLine( "The fully qualified name and path to this module is :{0}", myModuleBuilder->FullyQualifiedName );
   Type^ myType = myModuleBuilder->GetType( "TempClass" );
   MethodInfo^ myMethodInfo = myType->GetMethod( "MyMethod" );

   // Get the token used to identify the method within this module.
   MethodToken myMethodToken = myModuleBuilder->GetMethodToken( myMethodInfo );
   Console::WriteLine( "Token used to identify the method of 'myType'"
   " within the module is {0:x}", myMethodToken.Token );
   array<Object^>^args = {"Hello."};
   Object^ myObject = Activator::CreateInstance( myType, nullptr, nullptr );
   myMethodInfo->Invoke( myObject, args );
}
using System;
using System.Reflection;
using System.Reflection.Emit;
using System.Security.Permissions;

public class CodeGenerator
{
   AssemblyBuilder myAssemblyBuilder;
   public CodeGenerator()
   {
      // Get the current application domain for the current thread.
      AppDomain myCurrentDomain = AppDomain.CurrentDomain;
      AssemblyName myAssemblyName = new AssemblyName();
      myAssemblyName.Name = "TempAssembly";

      // Define a dynamic assembly in the current application domain.
      myAssemblyBuilder = myCurrentDomain.DefineDynamicAssembly
                     (myAssemblyName, AssemblyBuilderAccess.Run);

      // Define a dynamic module in this assembly.
      ModuleBuilder myModuleBuilder = myAssemblyBuilder.
                                      DefineDynamicModule("TempModule");

      // Define a runtime class with specified name and attributes.
      TypeBuilder myTypeBuilder = myModuleBuilder.DefineType
                                       ("TempClass",TypeAttributes.Public);

      // Add 'Greeting' field to the class, with the specified attribute and type.
      FieldBuilder greetingField = myTypeBuilder.DefineField("Greeting",
                                                            typeof(String), FieldAttributes.Public);
      Type[] myMethodArgs = { typeof(String) };

      // Add 'MyMethod' method to the class, with the specified attribute and signature.
      MethodBuilder myMethod = myTypeBuilder.DefineMethod("MyMethod",
         MethodAttributes.Public, CallingConventions.Standard, null,myMethodArgs);

      ILGenerator methodIL = myMethod.GetILGenerator();
      methodIL.EmitWriteLine("In the method...");
      methodIL.Emit(OpCodes.Ldarg_0);
      methodIL.Emit(OpCodes.Ldarg_1);
      methodIL.Emit(OpCodes.Stfld, greetingField);
      methodIL.Emit(OpCodes.Ret);
      myTypeBuilder.CreateType();
   }
   public AssemblyBuilder MyAssembly
   {
      get
      {
         return this.myAssemblyBuilder;
      }
   }
}
public class TestClass
{
   public static void Main()
   {
      CodeGenerator myCodeGenerator = new CodeGenerator();
      // Get the assembly builder for 'myCodeGenerator' object.
      AssemblyBuilder myAssemblyBuilder = myCodeGenerator.MyAssembly;
      // Get the module builder for the above assembly builder object .
      ModuleBuilder myModuleBuilder = myAssemblyBuilder.
                                                           GetDynamicModule("TempModule");
      Console.WriteLine("The fully qualified name and path to this "
                               + "module is :" +myModuleBuilder.FullyQualifiedName);
      Type myType = myModuleBuilder.GetType("TempClass");
      MethodInfo myMethodInfo =
                                                myType.GetMethod("MyMethod");
       // Get the token used to identify the method within this module.
      MethodToken myMethodToken =
                        myModuleBuilder.GetMethodToken(myMethodInfo);
      Console.WriteLine("Token used to identify the method of 'myType'"
                    + " within the module is {0:x}",myMethodToken.Token);
     object[] args={"Hello."};
     object myObject = Activator.CreateInstance(myType,null,null);
     myMethodInfo.Invoke(myObject,args);
   }
}
Imports System.Reflection
Imports System.Reflection.Emit
Imports System.Security.Permissions

Public Class CodeGenerator
   Private myAssemblyBuilder As AssemblyBuilder

   Public Sub New()
      ' Get the current application domain for the current thread.
      Dim myCurrentDomain As AppDomain = AppDomain.CurrentDomain
      Dim myAssemblyName As New AssemblyName()
      myAssemblyName.Name = "TempAssembly"

      ' Define a dynamic assembly in the current application domain.
      myAssemblyBuilder = _
               myCurrentDomain.DefineDynamicAssembly(myAssemblyName, AssemblyBuilderAccess.Run)

      ' Define a dynamic module in this assembly.
      Dim myModuleBuilder As ModuleBuilder = myAssemblyBuilder.DefineDynamicModule("TempModule")

      ' Define a runtime class with specified name and attributes.
      Dim myTypeBuilder As TypeBuilder = _
               myModuleBuilder.DefineType("TempClass", TypeAttributes.Public)

      ' Add 'Greeting' field to the class, with the specified attribute and type.
      Dim greetingField As FieldBuilder = _
               myTypeBuilder.DefineField("Greeting", GetType(String), FieldAttributes.Public)
      Dim myMethodArgs As Type() = {GetType(String)}

      ' Add 'MyMethod' method to the class, with the specified attribute and signature.
      Dim myMethod As MethodBuilder = _
               myTypeBuilder.DefineMethod("MyMethod", MethodAttributes.Public, _
               CallingConventions.Standard, Nothing, myMethodArgs)

      Dim methodIL As ILGenerator = myMethod.GetILGenerator()
      methodIL.EmitWriteLine("In the method...")
      methodIL.Emit(OpCodes.Ldarg_0)
      methodIL.Emit(OpCodes.Ldarg_1)
      methodIL.Emit(OpCodes.Stfld, greetingField)
      methodIL.Emit(OpCodes.Ret)
      myTypeBuilder.CreateType()
   End Sub

   Public ReadOnly Property MyAssembly() As AssemblyBuilder
      Get
         Return Me.myAssemblyBuilder
      End Get
   End Property
End Class

Public Class TestClass
   <PermissionSetAttribute(SecurityAction.Demand, Name:="FullTrust")> _
   Public Shared Sub Main()
      Dim myCodeGenerator As New CodeGenerator()
      ' Get the assembly builder for 'myCodeGenerator' object.
      Dim myAssemblyBuilder As AssemblyBuilder = myCodeGenerator.MyAssembly
      ' Get the module builder for the above assembly builder object .
      Dim myModuleBuilder As ModuleBuilder = myAssemblyBuilder.GetDynamicModule("TempModule")
      Console.WriteLine("The fully qualified name and path to this " + _
                        "module is :" + myModuleBuilder.FullyQualifiedName)
      Dim myType As Type = myModuleBuilder.GetType("TempClass")
      Dim myMethodInfo As MethodInfo = myType.GetMethod("MyMethod")
      ' Get the token used to identify the method within this module.
      Dim myMethodToken As MethodToken = myModuleBuilder.GetMethodToken(myMethodInfo)
      Console.WriteLine("Token used to identify the method of 'myType'" + _
                        " within the module is {0:x}", myMethodToken.Token)
      Dim args As Object() = {"Hello."}
      Dim myObject As Object = Activator.CreateInstance(myType, Nothing, Nothing)
      myMethodInfo.Invoke(myObject, args)
   End Sub
End Class

注釈

ModuleBuilderのインスタンスを取得するには、AssemblyBuilder.DefineDynamicModule メソッドを使用します。

コンストラクター

ModuleBuilder()

ModuleBuilder クラスの新しいインスタンスを初期化します。

プロパティ

Assembly

ModuleBuilderのこのインスタンスを定義した動的アセンブリを取得します。

Assembly

Moduleのこのインスタンスに適した Assembly を取得します。

(継承元 Module)
CustomAttributes

このモジュールのカスタム属性を含むコレクションを取得します。

(継承元 Module)
FullyQualifiedName

このモジュールの完全修飾名とパスを表す String を取得します。

MDStreamVersion

メタデータ ストリームのバージョンを取得します。

MDStreamVersion

メタデータ ストリームのバージョンを取得します。

(継承元 Module)
MetadataToken

メタデータ内の現在の動的モジュールを識別するトークンを取得します。

MetadataToken

メタデータ内のモジュールを識別するトークンを取得します。

(継承元 Module)
ModuleHandle

モジュールのハンドルを取得します。

(継承元 Module)
ModuleVersionId

モジュールの 2 つのバージョンを区別するために使用できる汎用一意識別子 (UUID) を取得します。

ModuleVersionId

モジュールの 2 つのバージョンを区別するために使用できる汎用一意識別子 (UUID) を取得します。

(継承元 Module)
Name

これがメモリ内モジュールであることを示す文字列。

Name

パスが削除されたモジュールの名前を表す String を取得します。

(継承元 Module)
ScopeName

動的モジュールの名前を表す文字列を取得します。

ScopeName

モジュールの名前を表す文字列を取得します。

(継承元 Module)

メソッド

CreateGlobalFunctions()

この動的モジュールのグローバル関数定義とグローバル データ定義を完了します。

CreateGlobalFunctionsCore()

派生クラスでオーバーライドされると、この動的モジュールのグローバル関数定義とグローバル データ定義が完了します。

DefineDocument(String, Guid)

ソースのドキュメントを定義します。

DefineDocument(String, Guid, Guid, Guid)

ソースのドキュメントを定義します。

DefineDocumentCore(String, Guid)

派生クラスでオーバーライドする場合は、ソースのドキュメントを定義します。

DefineEnum(String, TypeAttributes, Type)

指定した型の value__ と呼ばれる単一の非静的フィールドを持つ値型である列挙型を定義します。

DefineEnumCore(String, TypeAttributes, Type)

派生クラスでオーバーライドされた場合、指定した型のvalue__と呼ばれる単一の非静的フィールドを持つ値型である列挙型を定義します。

DefineGlobalMethod(String, MethodAttributes, CallingConventions, Type, Type[])

指定した名前、属性、呼び出し規則、戻り値の型、およびパラメーター型を持つグローバル メソッドを定義します。

DefineGlobalMethod(String, MethodAttributes, CallingConventions, Type, Type[], Type[], Type[], Type[][], Type[][])

指定した名前、属性、呼び出し規則、戻り値の型、戻り値の型のカスタム修飾子、パラメーター型、およびパラメーター型のカスタム修飾子を持つグローバル メソッドを定義します。

DefineGlobalMethod(String, MethodAttributes, Type, Type[])

指定した名前、属性、戻り値の型、およびパラメーター型を持つグローバル メソッドを定義します。

DefineGlobalMethodCore(String, MethodAttributes, CallingConventions, Type, Type[], Type[], Type[], Type[][], Type[][])

派生クラスでオーバーライドされると、指定した名前、属性、呼び出し規則、戻り値の型、戻り値の型のカスタム修飾子、パラメーター型、およびパラメーター型のカスタム修飾子を持つグローバル メソッドを定義します。

DefineInitializedData(String, Byte[], FieldAttributes)

ポータブル実行可能ファイル (PE) ファイルの .sdata セクションで初期化されたデータ フィールドを定義します。

DefineInitializedDataCore(String, Byte[], FieldAttributes)

派生クラスでオーバーライドされると、ポータブル実行可能ファイル (PE) ファイルの .sdata セクションで初期化されたデータ フィールドを定義します。

DefineManifestResource(String, Stream, ResourceAttributes)

動的アセンブリに埋め込むマニフェスト リソースを表すバイナリ ラージ オブジェクト (BLOB) を定義します。

DefinePInvokeMethod(String, String, MethodAttributes, CallingConventions, Type, Type[], CallingConvention, CharSet)

指定した名前、メソッドが定義されている DLL の名前、メソッドの属性、メソッドの呼び出し規則、メソッドの戻り値の型、メソッドのパラメーターの型、および PInvoke フラグを使用して、PInvoke メソッドを定義します。

DefinePInvokeMethod(String, String, String, MethodAttributes, CallingConventions, Type, Type[], CallingConvention, CharSet)

指定した名前、メソッドが定義されている DLL の名前、メソッドの属性、メソッドの呼び出し規則、メソッドの戻り値の型、メソッドのパラメーターの型、および PInvoke フラグを使用して、PInvoke メソッドを定義します。

DefinePInvokeMethodCore(String, String, String, MethodAttributes, CallingConventions, Type, Type[], CallingConvention, CharSet)

派生クラスでオーバーライドされると、PInvoke メソッドを定義します。

DefineResource(String, String)

このモジュールに格納する名前付きマネージド埋め込みリソースを定義します。

DefineResource(String, String, ResourceAttributes)

このモジュールに格納する特定の属性を使用して、名前付きマネージド埋め込みリソースを定義します。

DefineType(String)

このモジュールで指定した名前を持つプライベート型の TypeBuilder を構築します。

DefineType(String, TypeAttributes)

型名と型属性を指定して TypeBuilder を構築します。

DefineType(String, TypeAttributes, Type)

指定 TypeBuilder 型名、その属性、および定義された型が拡張する型を構築します。

DefineType(String, TypeAttributes, Type, Int32)

型名、属性、定義された型が拡張される型、および型の合計サイズを指定して、TypeBuilder を構築します。

DefineType(String, TypeAttributes, Type, PackingSize)

型名、属性、定義された型が拡張される型、および型のパッキング サイズを指定して、TypeBuilder を構築します。

DefineType(String, TypeAttributes, Type, PackingSize, Int32)

型名、属性、定義された型が拡張される型、定義された型のパッキング サイズ、および定義された型の合計サイズを指定して、TypeBuilder を構築します。

DefineType(String, TypeAttributes, Type, Type[])

型名、属性、定義された型が拡張される型、および定義された型が実装するインターフェイスを指定して、TypeBuilder を構築します。

DefineTypeCore(String, TypeAttributes, Type, Type[], PackingSize, Int32)

派生クラスでオーバーライドされると、TypeBuilderを構築します。

DefineUninitializedData(String, Int32, FieldAttributes)

ポータブル実行可能ファイル (PE) ファイルの .sdata セクションに初期化されていないデータ フィールドを定義します。

DefineUninitializedDataCore(String, Int32, FieldAttributes)

派生クラスでオーバーライドされると、ポータブル実行可能ファイル (PE) ファイルの .sdata セクションで初期化されていないデータ フィールドを定義します。

DefineUnmanagedResource(Byte[])

非管理対象の埋め込みリソースを定義します。非透過的なバイナリ ラージ オブジェクト (BLOB) のバイト数を指定します。

DefineUnmanagedResource(String)

Win32 リソース ファイルの名前を指定して、アンマネージ リソースを定義します。

Equals(Object)

このインスタンスが指定したオブジェクトと等しいかどうかを示す値を返します。

Equals(Object)

このモジュールと指定したオブジェクトが等しいかどうかを判断します。

(継承元 Module)
FindTypes(TypeFilter, Object)

指定されたフィルター条件とフィルター条件で受け入れられるクラスの配列を返します。

(継承元 Module)
GetArrayMethod(Type, String, CallingConventions, Type, Type[])

配列クラスの名前付きメソッドを返します。

GetArrayMethodCore(Type, String, CallingConventions, Type, Type[])

派生クラスでオーバーライドされると、配列クラスの名前付きメソッドを返します。

GetArrayMethodToken(Type, String, CallingConventions, Type, Type[])

配列クラスの名前付きメソッドのトークンを返します。

GetConstructorToken(ConstructorInfo)

このモジュール内で指定されたコンストラクターを識別するために使用されるトークンを返します。

GetConstructorToken(ConstructorInfo, IEnumerable<Type>)

このモジュール内で指定された属性とパラメーター型を持つコンストラクターを識別するために使用されるトークンを返します。

GetCustomAttributes(Boolean)

現在の ModuleBuilderに適用されているすべてのカスタム属性を返します。

GetCustomAttributes(Boolean)

すべてのカスタム属性を返します。

(継承元 Module)
GetCustomAttributes(Type, Boolean)

現在の ModuleBuilderに適用され、指定した属性型から派生したすべてのカスタム属性を返します。

GetCustomAttributes(Type, Boolean)

指定した型のカスタム属性を取得します。

(継承元 Module)
GetCustomAttributesData()

現在の ModuleBuilderに適用されている属性に関する情報 CustomAttributeData 返します。

GetCustomAttributesData()

リフレクションのみのコンテキストで使用できる、現在のモジュールの CustomAttributeData オブジェクトの一覧を返します。

(継承元 Module)
GetField(String)

指定した名前のフィールドを返します。

(継承元 Module)
GetField(String, BindingFlags)

指定した名前とバインド属性を持つ、ポータブル実行可能ファイル (PE) ファイルの .sdata 領域で定義されているモジュール レベルのフィールドを返します。

GetField(String, BindingFlags)

指定した名前とバインド属性を持つフィールドを返します。

(継承元 Module)
GetFieldMetadataToken(FieldInfo)

派生クラスでオーバーライドされると、Module を基準にして、指定された FieldInfo のメタデータ トークンを返します。

GetFields()

モジュールで定義されているグローバル フィールドを返します。

(継承元 Module)
GetFields(BindingFlags)

指定したバインド フラグに一致するポータブル実行可能 (PE) ファイルの .sdata 領域で定義されているすべてのフィールドを返します。

GetFields(BindingFlags)

指定したバインド フラグに一致するモジュールで定義されているグローバル フィールドを返します。

(継承元 Module)
GetFieldToken(FieldInfo)

このモジュール内の指定されたフィールドを識別するために使用されるトークンを返します。

GetHashCode()

このインスタンスのハッシュ コードを返します。

GetHashCode()

このインスタンスのハッシュ コードを返します。

(継承元 Module)
GetMethod(String)

指定した名前のメソッドを返します。

(継承元 Module)
GetMethod(String, BindingFlags, Binder, CallingConventions, Type[], ParameterModifier[])

指定した名前、バインディング情報、呼び出し規則、およびパラメーターの型と修飾子を持つメソッドを返します。

(継承元 Module)
GetMethod(String, Type[])

指定した名前とパラメーター型を持つメソッドを返します。

(継承元 Module)
GetMethodImpl(String, BindingFlags, Binder, CallingConventions, Type[], ParameterModifier[])

指定した条件に一致するモジュール レベルのメソッドを返します。

GetMethodImpl(String, BindingFlags, Binder, CallingConventions, Type[], ParameterModifier[])

指定した条件に従ってメソッドの実装を返します。

(継承元 Module)
GetMethodMetadataToken(ConstructorInfo)

派生クラスでオーバーライドされると、Module を基準にして、指定された ConstructorInfo のメタデータ トークンを返します。

GetMethodMetadataToken(MethodInfo)

派生クラスでオーバーライドされると、Module を基準にして、指定された MethodInfo のメタデータ トークンを返します。

GetMethods()

モジュールで定義されているグローバル メソッドを返します。

(継承元 Module)
GetMethods(BindingFlags)

現在の ModuleBuilderのモジュール レベルで定義され、指定されたバインド フラグに一致するすべてのメソッドを返します。

GetMethods(BindingFlags)

指定したバインド フラグに一致するモジュールで定義されているグローバル メソッドを返します。

(継承元 Module)
GetMethodToken(MethodInfo)

このモジュール内で指定されたメソッドを識別するために使用されるトークンを返します。

GetMethodToken(MethodInfo, IEnumerable<Type>)

このモジュール内で指定された属性とパラメーター型を持つメソッドを識別するために使用されるトークンを返します。

GetObjectData(SerializationInfo, StreamingContext)
古い.

シリアル化されたオブジェクトの ISerializable 実装を提供します。

(継承元 Module)
GetPEKind(PortableExecutableKinds, ImageFileMachine)

モジュール内のコードの性質と、モジュールの対象となるプラットフォームを示す値のペアを取得します。

GetPEKind(PortableExecutableKinds, ImageFileMachine)

モジュール内のコードの性質と、モジュールの対象となるプラットフォームを示す値のペアを取得します。

(継承元 Module)
GetSignatureMetadataToken(SignatureHelper)

派生クラスでオーバーライドされると、Module を基準にして、指定された SignatureHelper のメタデータ トークンを返します。

GetSignatureToken(Byte[], Int32)

指定した文字配列と署名の長さを持つ署名のトークンを定義します。

GetSignatureToken(SignatureHelper)

指定した SignatureHelperによって定義される署名のトークンを定義します。

GetSignerCertificate()

このモジュールが属するアセンブリの Authenticode 署名に含まれる証明書に対応する X509Certificate オブジェクトを返します。 アセンブリが Authenticode 署名されていない場合は、null が返されます。

GetSignerCertificate()

このモジュールが属するアセンブリの Authenticode 署名に含まれる証明書に対応する X509Certificate オブジェクトを返します。 アセンブリが Authenticode 署名されていない場合は、null が返されます。

(継承元 Module)
GetStringConstant(String)

モジュールの定数プール内の指定された文字列のトークンを返します。

GetStringMetadataToken(String)

派生クラスでオーバーライドされた場合は、Module を基準にして、指定された String 定数のメタデータ トークンを返します。

GetSymWriter()

この動的モジュールに関連付けられているシンボル ライターを返します。

GetType()

現在のインスタンスの Type を取得します。

(継承元 Object)
GetType(String)

モジュールで定義されている名前付き型を取得します。

GetType(String)

大文字と小文字を区別する検索を実行して、指定した型を返します。

(継承元 Module)
GetType(String, Boolean)

必要に応じて型名の大文字と小文字を区別しないで、モジュールで定義されている名前付き型を取得します。

GetType(String, Boolean)

指定した型を返し、指定した大文字と小文字を区別してモジュールを検索します。

(継承元 Module)
GetType(String, Boolean, Boolean)

必要に応じて型名の大文字と小文字を区別しないで、モジュールで定義されている名前付き型を取得します。 必要に応じて、型が見つからない場合に例外をスローします。

GetType(String, Boolean, Boolean)

モジュールの大文字と小文字を区別する検索を行うかどうか、および型が見つからない場合に例外をスローするかどうかを指定して、指定した型を返します。

(継承元 Module)
GetTypeMetadataToken(Type)

派生クラスでオーバーライドされると、Module を基準にして、指定された Type のメタデータ トークンを返します。

GetTypes()

このモジュール内で定義されているすべてのクラスを返します。

GetTypes()

このモジュール内で定義されているすべての型を返します。

(継承元 Module)
GetTypeToken(String)

指定した名前を持つ型を識別するために使用されるトークンを返します。

GetTypeToken(Type)

このモジュール内で指定された型を識別するために使用されるトークンを返します。

IsDefined(Type, Boolean)

指定した属性型がこのモジュールに適用されているかどうかを示す値を返します。

IsDefined(Type, Boolean)

指定した属性型がこのモジュールに適用されているかどうかを示す値を返します。

(継承元 Module)
IsResource()

オブジェクトがリソースであるかどうかを示す値を取得します。

IsResource()

オブジェクトがリソースであるかどうかを示す値を取得します。

(継承元 Module)
IsTransient()

この動的モジュールが一時的であるかどうかを示す値を返します。

MemberwiseClone()

現在の Objectの簡易コピーを作成します。

(継承元 Object)
ResolveField(Int32)

指定したメタデータ トークンによって識別されるフィールドを返します。

(継承元 Module)
ResolveField(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別されるフィールドを返します。

ResolveField(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別されるフィールドを返します。

(継承元 Module)
ResolveMember(Int32)

指定したメタデータ トークンによって識別される型またはメンバーを返します。

(継承元 Module)
ResolveMember(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別される型またはメンバーを返します。

ResolveMember(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別される型またはメンバーを返します。

(継承元 Module)
ResolveMethod(Int32)

指定したメタデータ トークンによって識別されるメソッドまたはコンストラクターを返します。

(継承元 Module)
ResolveMethod(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別されるメソッドまたはコンストラクターを返します。

ResolveMethod(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別されるメソッドまたはコンストラクターを返します。

(継承元 Module)
ResolveSignature(Int32)

メタデータ トークンによって識別される署名 BLOB を返します。

ResolveSignature(Int32)

メタデータ トークンによって識別される署名 BLOB を返します。

(継承元 Module)
ResolveString(Int32)

指定したメタデータ トークンによって識別される文字列を返します。

ResolveString(Int32)

指定したメタデータ トークンによって識別される文字列を返します。

(継承元 Module)
ResolveType(Int32)

指定したメタデータ トークンによって識別される型を返します。

(継承元 Module)
ResolveType(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別される型を返します。

ResolveType(Int32, Type[], Type[])

指定したジェネリック型パラメーターによって定義されたコンテキストで、指定したメタデータ トークンによって識別される型を返します。

(継承元 Module)
SetCustomAttribute(ConstructorInfo, Byte[])

属性を表す指定されたバイナリ ラージ オブジェクト (BLOB) を使用して、このモジュールにカスタム属性を適用します。

SetCustomAttribute(CustomAttributeBuilder)

カスタム属性ビルダーを使用して、このモジュールにカスタム属性を適用します。

SetCustomAttributeCore(ConstructorInfo, ReadOnlySpan<Byte>)

派生クラスでオーバーライドされた場合は、このアセンブリにカスタム属性を設定します。

SetSymCustomAttribute(String, Byte[])

このメソッドは何も行いません。

SetUserEntryPoint(MethodInfo)

ユーザー エントリ ポイントを設定します。

ToString()

モジュールの名前を返します。

(継承元 Module)

明示的なインターフェイスの実装

_Module.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)

名前のセットを、対応するディスパッチ識別子のセットにマップします。

(継承元 Module)
_Module.GetTypeInfo(UInt32, UInt32, IntPtr)

オブジェクトの型情報を取得します。これを使用して、インターフェイスの型情報を取得できます。

(継承元 Module)
_Module.GetTypeInfoCount(UInt32)

オブジェクトが提供する型情報インターフェイスの数を取得します (0 または 1)。

(継承元 Module)
_Module.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)

オブジェクトによって公開されるプロパティとメソッドへのアクセスを提供します。

(継承元 Module)
_ModuleBuilder.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)

このメンバーの説明については、GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)を参照してください。

_ModuleBuilder.GetTypeInfo(UInt32, UInt32, IntPtr)

このメンバーの説明については、GetTypeInfo(UInt32, UInt32, IntPtr)を参照してください。

_ModuleBuilder.GetTypeInfoCount(UInt32)

このメンバーの説明については、GetTypeInfoCount(UInt32)を参照してください。

_ModuleBuilder.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)

このメンバーの説明については、Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)を参照してください。

ICustomAttributeProvider.GetCustomAttributes(Boolean)

名前付き属性を除き、このメンバーで定義されているすべてのカスタム属性の配列を返します。カスタム属性がない場合は空の配列を返します。

(継承元 Module)
ICustomAttributeProvider.GetCustomAttributes(Type, Boolean)

このメンバーで定義されているカスタム属性の配列を型で識別するか、その型のカスタム属性がない場合は空の配列を返します。

(継承元 Module)
ICustomAttributeProvider.IsDefined(Type, Boolean)

attributeType の 1 つ以上のインスタンスがこのメンバーで定義されているかどうかを示します。

(継承元 Module)

拡張メソッド

GetCustomAttribute(Module, Type)

指定したモジュールに適用される、指定した型のカスタム属性を取得します。

GetCustomAttribute<T>(Module)

指定したモジュールに適用される、指定した型のカスタム属性を取得します。

GetCustomAttributes(Module)

指定したモジュールに適用されるカスタム属性のコレクションを取得します。

GetCustomAttributes(Module, Type)

指定したモジュールに適用される、指定した型のカスタム属性のコレクションを取得します。

GetCustomAttributes<T>(Module)

指定したモジュールに適用される、指定した型のカスタム属性のコレクションを取得します。

IsDefined(Module, Type)

指定した型のカスタム属性が指定したモジュールに適用されるかどうかを示します。

GetModuleVersionId(Module)

動的アセンブリ内のモジュールを定義して表します。

HasModuleVersionId(Module)

動的アセンブリ内のモジュールを定義して表します。

適用対象