PropertyBuilder::GetCustomAttributes Method (Boolean)

 

Returns an array of all the custom attributes for this property.

Namespace:   System.Reflection.Emit
Assembly:  mscorlib (in mscorlib.dll)

public:
virtual array<Object^>^ GetCustomAttributes(
	bool inherit
) override

Parameters

inherit
Type: System::Boolean

If true, walks up this property's inheritance chain to find the custom attributes

Return Value

Type: array<System::Object^>^

An array of all the custom attributes.

Exception Condition
NotSupportedException

This method is not supported.

Reflect on the property's parent type using Type.GetType or Assembly.GetType, retrieve the Reflection property object from the type, and call PropertyInfo.GetCustomAttributes.

.NET Framework
Available since 1.1
Silverlight
Available since 2.0
Return to top
Show: