CustomAttributeArgument Class

Represents an argument passed to a custom attribute.

public class CustomAttributeArgument : CodeObject, ICommentable
Inheritance
CodeObject CustomAttributeArgument
Implements

Constructors

NameDescription
CustomAttributeArgument()
CustomAttributeArgument(Expression?)Initializes a new instance of the CustomAttributeArgument class with the specified value.
CustomAttributeArgument(string?, Expression?)Initializes a new instance of the CustomAttributeArgument class with the specified property name and value.

CustomAttributeArgument overloads

CustomAttributeArgument()

CustomAttributeArgument.cs
public CustomAttributeArgument()

No documentation is available.

CustomAttributeArgument(Expression?)

CustomAttributeArgument.cs

Initializes a new instance of the CustomAttributeArgument class with the specified value.

public CustomAttributeArgument(Expression? value)
Parameters
value Expression?
The argument value.

CustomAttributeArgument(string?, Expression?)

CustomAttributeArgument.cs

Initializes a new instance of the CustomAttributeArgument class with the specified property name and value.

public CustomAttributeArgument(string? propertyName, Expression? value)
Parameters
propertyName string?
The property name for named arguments, or null for positional arguments.
value Expression?
The argument value.

Properties

NameDescription
CommentsAfter
CommentsBefore
PropertyName
Value
public CommentCollection CommentsAfter { get; }

Property value

CommentCollection

No documentation is available.

public CommentCollection CommentsBefore { get; }

Property value

CommentCollection

No documentation is available.

public string? PropertyName { get; set; }

Property value

string?

No documentation is available.

public Expression? Value { get; set; }

Property value

Expression?

No documentation is available.