ForeignKeyIndexConvention.AreIndexedBy 方法

定義

傳回值,指出現有索引是否已經涵蓋指定的屬性。

protected virtual bool AreIndexedBy (System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> properties, bool unique, System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> coveringIndexProperties, bool coveringIndexUnique);
abstract member AreIndexedBy : System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> * bool * System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> * bool -> bool
override this.AreIndexedBy : System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> * bool * System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> * bool -> bool
Protected Overridable Function AreIndexedBy (properties As IReadOnlyList(Of IConventionProperty), unique As Boolean, coveringIndexProperties As IReadOnlyList(Of IConventionProperty), coveringIndexUnique As Boolean) As Boolean

參數

properties
IReadOnlyList<IConventionProperty>

要檢查的屬性。

unique
Boolean

要建立的索引是否應是唯一的。

coveringIndexProperties
IReadOnlyList<IConventionProperty>

現有索引的屬性。

coveringIndexUnique
Boolean

現有索引是否是唯一的。

傳回

true 如果現有的索引涵蓋指定的屬性,則為 。

適用於