ConventionAnnotatableExtensions.AddAnnotations 方法

定义

向 对象添加批注。

public static void AddAnnotations (this Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotatable annotatable, System.Collections.Generic.IEnumerable<Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotation> annotations, bool fromDataAnnotation = false);
static member AddAnnotations : Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotatable * seq<Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotation> * bool -> unit
<Extension()>
Public Sub AddAnnotations (annotatable As IConventionAnnotatable, annotations As IEnumerable(Of IConventionAnnotation), Optional fromDataAnnotation As Boolean = false)

参数

annotatable
IConventionAnnotatable

要向其添加批注的对象。

annotations
IEnumerable<IConventionAnnotation>

要添加的批注。

fromDataAnnotation
Boolean

指示是否使用数据注释指定配置。

适用于