GenericTypeParameterBuilder.SetCustomAttribute Método

Definición

Establece un atributo personalizado.

Sobrecargas

Nombre Description
SetCustomAttribute(CustomAttributeBuilder)

Establezca un atributo personalizado mediante un generador de atributos personalizados.

SetCustomAttribute(ConstructorInfo, Byte[])

Establece un atributo personalizado mediante un blob de atributo personalizado especificado.

SetCustomAttribute(CustomAttributeBuilder)

Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs

Establezca un atributo personalizado mediante un generador de atributos personalizados.

public:
 void SetCustomAttribute(System::Reflection::Emit::CustomAttributeBuilder ^ customBuilder);
public void SetCustomAttribute(System.Reflection.Emit.CustomAttributeBuilder customBuilder);
member this.SetCustomAttribute : System.Reflection.Emit.CustomAttributeBuilder -> unit
Public Sub SetCustomAttribute (customBuilder As CustomAttributeBuilder)

Parámetros

customBuilder
CustomAttributeBuilder

Instancia de una clase auxiliar que define el atributo personalizado.

Excepciones

customBuilder es null.

Se aplica a

SetCustomAttribute(ConstructorInfo, Byte[])

Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs
Source:
GenericTypeParameterBuilder.cs

Establece un atributo personalizado mediante un blob de atributo personalizado especificado.

public:
 void SetCustomAttribute(System::Reflection::ConstructorInfo ^ con, cli::array <System::Byte> ^ binaryAttribute);
public void SetCustomAttribute(System.Reflection.ConstructorInfo con, byte[] binaryAttribute);
member this.SetCustomAttribute : System.Reflection.ConstructorInfo * byte[] -> unit
Public Sub SetCustomAttribute (con As ConstructorInfo, binaryAttribute As Byte())

Parámetros

con
ConstructorInfo

Constructor del atributo personalizado.

binaryAttribute
Byte[]

Un blob de bytes que representa el atributo .

Excepciones

con es null.

O bien

binaryAttribute es una referencia nula.

Comentarios

Para obtener información sobre cómo dar formato binaryAttributea , consulte la especificación de metadatos de la especificación de Common Language Infrastructure (CLI) en partición II.

Se aplica a