ParameterInfoGetCustomAttributes Method (Type, Boolean) |
Gets the custom attributes of the specified type or its derived types that are applied to this parameter.
Namespace: System.ReflectionAssembly: mscorlib (in mscorlib.dll) Version: 4.0.0.0
Syntax 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:
ObjectAn array that contains the custom attributes of the specified type or its derived types.
Exceptions Exception | Condition |
---|
ArgumentException | The type must be a type provided by the underlying runtime system. |
ArgumentNullException | attributeType is null. |
TypeLoadException | A custom attribute type could not be loaded. |
See Also