ForeignKeyIndexConvention.AreIndexedBy Method

Definition

Returns a value indicating whether the given properties are already covered by an existing index.

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

Parameters

properties
IReadOnlyList<IConventionProperty>

The properties to check.

unique
Boolean

Whether the index to create should be unique.

coveringIndexProperties
IReadOnlyList<IConventionProperty>

The properties of an existing index.

coveringIndexUnique
Boolean

Whether the existing index is unique.

Returns

true if the existing index covers the given properties.

Applies to