Partager via


RuntimeEntityType.AddIndex Méthode

Définition

Ajoute un index à ce type d’entité.

public virtual Microsoft.EntityFrameworkCore.Metadata.RuntimeIndex AddIndex (System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.RuntimeProperty> properties, string? name = default, bool unique = false);
abstract member AddIndex : System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.RuntimeProperty> * string * bool -> Microsoft.EntityFrameworkCore.Metadata.RuntimeIndex
override this.AddIndex : System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.RuntimeProperty> * string * bool -> Microsoft.EntityFrameworkCore.Metadata.RuntimeIndex
Public Overridable Function AddIndex (properties As IReadOnlyList(Of RuntimeProperty), Optional name As String = Nothing, Optional unique As Boolean = false) As RuntimeIndex

Paramètres

properties
IReadOnlyList<RuntimeProperty>

Propriétés à indexer.

name
String

Nom de l’index.

unique
Boolean

Valeur indiquant si les valeurs attribuées aux propriétés indexées sont uniques.

Retours

Index nouvellement créé.

S’applique à