Udostępnij przez


AssemblyBuilder.GetCustomAttributesData Metoda

Definicja

Zwraca CustomAttributeData obiekty zawierające informacje o atrybutach, które zostały zastosowane do bieżącego AssemblyBuilderobiektu .

public:
 override System::Collections::Generic::IList<System::Reflection::CustomAttributeData ^> ^ GetCustomAttributesData();
public override System.Collections.Generic.IList<System.Reflection.CustomAttributeData> GetCustomAttributesData ();
override this.GetCustomAttributesData : unit -> System.Collections.Generic.IList<System.Reflection.CustomAttributeData>
Public Overrides Function GetCustomAttributesData () As IList(Of CustomAttributeData)

Zwraca

Ogólna lista CustomAttributeData obiektów reprezentujących dane dotyczące atrybutów, które zostały zastosowane do bieżącego modułu.

Uwagi

Ta metoda służy do badania atrybutów niestandardowych kodu w kontekście tylko odbicia, w przypadkach, gdy same atrybuty niestandardowe są zdefiniowane w kodzie, który jest ładowany do kontekstu tylko odbicia. Metody takie jak Attribute.GetCustomAttributes i Assembly.GetCustomAttributes nie mogą być używane w takich przypadkach, ponieważ tworzą wystąpienia atrybutów. Nie można wykonać kodu w kontekście tylko odbicia. Aby uzyskać więcej informacji i na przykład kod, zobacz klasę CustomAttributeData .

Dotyczy