Assembly.GetCustomAttributesData Metodo

Definizione

Restituisce informazioni sugli attributi applicati all'oggetto Assembly corrente, espresse sotto forma di oggetti CustomAttributeData.

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

Restituisce

IList<CustomAttributeData>

Elenco generico di oggetti CustomAttributeData che rappresentano i dati relativi agli attributi applicati all'assembly corrente.

Commenti

Utilizzare questo metodo per esaminare gli attributi personalizzati del codice nel contesto reflection-only, nei casi in cui gli attributi personalizzati stessi sono definiti nel codice caricato nel contesto reflection-only. Metodi come Attribute.GetCustomAttributes e non possono essere usati in questi Assembly.GetCustomAttributes casi, perché creano istanze degli attributi. Non è possibile eseguire codice nel contesto reflection-only. Per altre informazioni e per codice di esempio, vedere la CustomAttributeData classe .

Si applica a