GenericTypeParameterBuilder.SetCustomAttribute Metoda

Definicja

Ustawia atrybut niestandardowy.

Przeciążenia

SetCustomAttribute(CustomAttributeBuilder)

Ustaw atrybut niestandardowy przy użyciu konstruktora atrybutów niestandardowych.

SetCustomAttribute(ConstructorInfo, Byte[])

Ustawia atrybut niestandardowy przy użyciu określonego obiektu blob atrybutu niestandardowego.

SetCustomAttribute(CustomAttributeBuilder)

Źródło:
GenericTypeParameterBuilder.cs
Źródło:
GenericTypeParameterBuilder.cs
Źródło:
GenericTypeParameterBuilder.cs

Ustaw atrybut niestandardowy przy użyciu konstruktora atrybutów niestandardowych.

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)

Parametry

customBuilder
CustomAttributeBuilder

Wystąpienie klasy pomocniczej, która definiuje atrybut niestandardowy.

Wyjątki

customBuilder to null.

Dotyczy

SetCustomAttribute(ConstructorInfo, Byte[])

Źródło:
GenericTypeParameterBuilder.cs
Źródło:
GenericTypeParameterBuilder.cs
Źródło:
GenericTypeParameterBuilder.cs

Ustawia atrybut niestandardowy przy użyciu określonego obiektu blob atrybutu niestandardowego.

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())

Parametry

con
ConstructorInfo

Konstruktor atrybutu niestandardowego.

binaryAttribute
Byte[]

Bajtowy obiekt blob reprezentujący atrybut.

Wyjątki

con to null.

-lub-

binaryAttribute jest odwołaniem o wartości null.

Uwagi

Aby uzyskać informacje na temat formatowania binaryAttribute, zobacz specyfikację metadanych w sekcji Partition II specyfikacji infrastruktury języka wspólnego (CLI).

Dotyczy