Class AttributeCodeFragment
- Namespace
- Microsoft.EntityFrameworkCore.Design
- Assembly
- Microsoft.EntityFrameworkCore.dll
Represents usage of an attribute.
public class AttributeCodeFragment
- Inheritance
-
AttributeCodeFragment
- Inherited Members
Remarks
See Implementation of database providers and extensions for more information and examples.
Constructors
AttributeCodeFragment(Type, IEnumerable<object?>, IDictionary<string, object?>)
Initializes a new instance of the AttributeCodeFragment class.
public AttributeCodeFragment(Type type, IEnumerable<object?> arguments, IDictionary<string, object?> namedArguments)
Parameters
type
TypeThe attribute's CLR type.
arguments
IEnumerable<object>The attribute's positional arguments.
namedArguments
IDictionary<string, object>The attribute's named arguments.
AttributeCodeFragment(Type, params object?[])
Initializes a new instance of the AttributeCodeFragment class.
public AttributeCodeFragment(Type type, params object?[] arguments)
Parameters
Properties
Arguments
Gets the attribute's positional arguments.
public virtual IReadOnlyList<object?> Arguments { get; }
Property Value
- IReadOnlyList<object>
The arguments.
NamedArguments
Gets the attribute's named arguments.
public virtual IReadOnlyDictionary<string, object?> NamedArguments { get; }
Property Value
- IReadOnlyDictionary<string, object>
The arguments.
Type
Gets or sets the attribute's type.
public virtual Type Type { get; }
Property Value
- Type
The attribute's type.