CustomAttributeNamedArgument Constructor (MemberInfo^, Object^)

.NET Framework (current version)
 

Initializes a new instance of the CustomAttributeNamedArgument class, which represents the specified field or property of the custom attribute, and specifies the value of the field or property.

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

public:
CustomAttributeNamedArgument(
	MemberInfo^ memberInfo,
	Object^ value
)

Parameters

memberInfo
Type: System.Reflection::MemberInfo^

A field or property of the custom attribute. The new CustomAttributeNamedArgument object represents this member and its value.

value
Type: System::Object^

The value of the field or property of the custom attribute.

Exception Condition
ArgumentNullException

memberInfo is null.

ArgumentException

memberInfo is not a field or property of the custom attribute.

This constructor is for use by inheritors of the CustomAttributeNamedArgument class. It is not intended for use in application code.

.NET Framework
Available since 4.0
Return to top
Show: