Click or drag to resize
ParameterInfoGetCustomAttributes Method (Type, Boolean)
Gets the custom attributes of the specified type or its derived types that are applied to this parameter.

Namespace: System.Reflection
Assembly: mscorlib (in mscorlib.dll) Version: 4.0.0.0
Syntax
C#
public virtual Object[] GetCustomAttributes(
	Type attributeType,
	bool inherit
)

Parameters

attributeType
Type: SystemType
The custom attributes identified by type.
inherit
Type: SystemBoolean
This argument is ignored for objects of this type. See Remarks.

Return Value

Type: Object
An array that contains the custom attributes of the specified type or its derived types.
Exceptions
ExceptionCondition
ArgumentExceptionThe type must be a type provided by the underlying runtime system.
ArgumentNullExceptionattributeType is null.
TypeLoadExceptionA custom attribute type could not be loaded.
See Also