语言

ConventionsConfiguration.AddBefore<TExistingConvention> 方法

定义

为 . DbModelBuilder启用配置约定。 此约定将在指定的约定之前运行。

[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1004:GenericMethodsShouldProvideTypeParameter")]
public void AddBefore<TExistingConvention>(System.Data.Entity.ModelConfiguration.Conventions.IConvention newConvention) where TExistingConvention : System.Data.Entity.ModelConfiguration.Conventions.IConvention;
member this.AddBefore : System.Data.Entity.ModelConfiguration.Conventions.IConvention -> unit (requires 'ExistingConvention :> System.Data.Entity.ModelConfiguration.Conventions.IConvention)
Public Sub AddBefore(Of TExistingConvention As IConvention) (newConvention As IConvention)

类型参数

TExistingConvention

启用的约定将运行之前的类型。

参数

newConvention
IConvention

要启用的约定。

特性

适用于