ConventionSet.Replace 方法

定义

重载

Replace<TConvention,TImplementation>(List<TConvention>, TImplementation)

将现有约定替换为派生约定。

Replace<TConvention,TImplementation>(IList<TConvention>, TImplementation)

将现有约定替换为派生约定。

Replace<TImplementation>(TImplementation)

将现有约定替换为派生约定。 此外,为现有约定未实现的任何约定类型注册新约定。

Replace<TConvention,TImplementation>(List<TConvention>, TImplementation)

Source:
ConventionSet.cs
Source:
ConventionSet.cs
Source:
ConventionSet.cs

将现有约定替换为派生约定。

public static bool Replace<TConvention,TImplementation> (System.Collections.Generic.List<TConvention> conventionsList, TImplementation newConvention) where TImplementation : TConvention;
static member Replace : System.Collections.Generic.List<'Convention> * 'Implementation -> bool
Public Shared Function Replace(Of TConvention, TImplementation) (conventionsList As List(Of TConvention), newConvention As TImplementation) As Boolean

类型参数

TConvention

要替换的约定的类型。

TImplementation

旧约定的类型。

参数

conventionsList
List<TConvention>

要扫描的现有约定实例的列表。

newConvention
TImplementation

新约定。

返回

true 如果替换了约定,则为 。

适用于

Replace<TConvention,TImplementation>(IList<TConvention>, TImplementation)

Source:
ConventionSet.cs
Source:
ConventionSet.cs
Source:
ConventionSet.cs
Source:
ConventionSet.cs

将现有约定替换为派生约定。

public static bool Replace<TConvention,TImplementation> (System.Collections.Generic.IList<TConvention> conventionsList, TImplementation newConvention) where TImplementation : TConvention;
static member Replace : System.Collections.Generic.IList<'Convention> * 'Implementation -> bool
Public Shared Function Replace(Of TConvention, TImplementation) (conventionsList As IList(Of TConvention), newConvention As TImplementation) As Boolean

类型参数

TConvention

要替换的约定的类型。

TImplementation

旧约定的类型。

参数

conventionsList
IList<TConvention>

要扫描的现有约定实例的列表。

newConvention
TImplementation

新约定。

返回

true 如果替换了约定,则为 。

适用于

Replace<TImplementation>(TImplementation)

Source:
ConventionSet.cs
Source:
ConventionSet.cs
Source:
ConventionSet.cs

将现有约定替换为派生约定。 此外,为现有约定未实现的任何约定类型注册新约定。

public virtual void Replace<TImplementation> (TImplementation newConvention) where TImplementation : Microsoft.EntityFrameworkCore.Metadata.Conventions.IConvention;
abstract member Replace : 'Implementation -> unit (requires 'Implementation :> Microsoft.EntityFrameworkCore.Metadata.Conventions.IConvention)
override this.Replace : 'Implementation -> unit (requires 'Implementation :> Microsoft.EntityFrameworkCore.Metadata.Conventions.IConvention)
Public Overridable Sub Replace(Of TImplementation As IConvention) (newConvention As TImplementation)

类型参数

TImplementation

旧约定的类型。

参数

newConvention
TImplementation

新约定。

适用于