ModelCodeGenerationOptions.UseDataAnnotations Property

Definition

Gets or sets a value indicating whether to use data annotations.

C#
public virtual bool UseDataAnnotations { get; set; }

Property Value

A value indicating whether to use data annotations.

Applies to

Product Versions
Entity Framework Core 2.1, 2.2, 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0