MutableEntityTypeExtensions.AddIndex Method

Definition

Adds an index to this entity type.

public static Microsoft.EntityFrameworkCore.Metadata.IMutableIndex AddIndex (this Microsoft.EntityFrameworkCore.Metadata.IMutableEntityType entityType, Microsoft.EntityFrameworkCore.Metadata.IMutableProperty property);
static member AddIndex : Microsoft.EntityFrameworkCore.Metadata.IMutableEntityType * Microsoft.EntityFrameworkCore.Metadata.IMutableProperty -> Microsoft.EntityFrameworkCore.Metadata.IMutableIndex
<Extension()>
Public Function AddIndex (entityType As IMutableEntityType, property As IMutableProperty) As IMutableIndex

Parameters

entityType
IMutableEntityType

The entity type.

property
IMutableProperty

The property to be indexed.

Returns

The newly created index.

Applies to