AssemblyBuilder.DefineDynamicAssembly 方法

定义

定义动态程序集。Defines a dynamic assembly.

重载

DefineDynamicAssembly(AssemblyName, AssemblyBuilderAccess)

定义具有指定名称和访问权限的动态程序集。Defines a dynamic assembly that has the specified name and access rights.

DefineDynamicAssembly(AssemblyName, AssemblyBuilderAccess, IEnumerable<CustomAttributeBuilder>)

定义具有指定名称、访问权限和属性的新程序集。Defines a new assembly that has the specified name, access rights, and attributes.

DefineDynamicAssembly(AssemblyName, AssemblyBuilderAccess)

定义具有指定名称和访问权限的动态程序集。Defines a dynamic assembly that has the specified name and access rights.

public:
 static System::Reflection::Emit::AssemblyBuilder ^ DefineDynamicAssembly(System::Reflection::AssemblyName ^ name, System::Reflection::Emit::AssemblyBuilderAccess access);
public static System.Reflection.Emit.AssemblyBuilder DefineDynamicAssembly (System.Reflection.AssemblyName name, System.Reflection.Emit.AssemblyBuilderAccess access);
static member DefineDynamicAssembly : System.Reflection.AssemblyName * System.Reflection.Emit.AssemblyBuilderAccess -> System.Reflection.Emit.AssemblyBuilder
Public Shared Function DefineDynamicAssembly (name As AssemblyName, access As AssemblyBuilderAccess) As AssemblyBuilder

参数

name
AssemblyName

程序集的名称。The name of the assembly.

access
AssemblyBuilderAccess

程序集的访问权限。The access rights of the assembly.

返回

AssemblyBuilder

表示新程序集的对象。An object that represents the new assembly.

适用于

DefineDynamicAssembly(AssemblyName, AssemblyBuilderAccess, IEnumerable<CustomAttributeBuilder>)

定义具有指定名称、访问权限和属性的新程序集。Defines a new assembly that has the specified name, access rights, and attributes.

public:
 static System::Reflection::Emit::AssemblyBuilder ^ DefineDynamicAssembly(System::Reflection::AssemblyName ^ name, System::Reflection::Emit::AssemblyBuilderAccess access, System::Collections::Generic::IEnumerable<System::Reflection::Emit::CustomAttributeBuilder ^> ^ assemblyAttributes);
public static System.Reflection.Emit.AssemblyBuilder DefineDynamicAssembly (System.Reflection.AssemblyName name, System.Reflection.Emit.AssemblyBuilderAccess access, System.Collections.Generic.IEnumerable<System.Reflection.Emit.CustomAttributeBuilder>? assemblyAttributes);
public static System.Reflection.Emit.AssemblyBuilder DefineDynamicAssembly (System.Reflection.AssemblyName name, System.Reflection.Emit.AssemblyBuilderAccess access, System.Collections.Generic.IEnumerable<System.Reflection.Emit.CustomAttributeBuilder> assemblyAttributes);
static member DefineDynamicAssembly : System.Reflection.AssemblyName * System.Reflection.Emit.AssemblyBuilderAccess * seq<System.Reflection.Emit.CustomAttributeBuilder> -> System.Reflection.Emit.AssemblyBuilder
Public Shared Function DefineDynamicAssembly (name As AssemblyName, access As AssemblyBuilderAccess, assemblyAttributes As IEnumerable(Of CustomAttributeBuilder)) As AssemblyBuilder

参数

name
AssemblyName

程序集的名称。The name of the assembly.

access
AssemblyBuilderAccess

程序集的访问权限。The access rights of the assembly.

assemblyAttributes
IEnumerable<CustomAttributeBuilder>

包含程序集属性的集合。A collection that contains the attributes of the assembly.

返回

AssemblyBuilder

表示新程序集的对象。An object that represents the new assembly.

适用于