ModuleBuilder.GetCustomAttributesData Metoda

Definicja

Zwraca informacje o atrybutach, które zostały zastosowane do bieżącej ModuleBuilderwartości , wyrażonej jako CustomAttributeData obiekty.

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 niestandardowych atrybutów kodu w kontekście tylko odbicia, w przypadkach, gdy same atrybuty niestandardowe są definiowane w kodzie załadowanym 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 kodu, zobacz klasę CustomAttributeData .

Dotyczy