MutableEntityTypeExtensions.AddIndex 方法

定義

將索引加入至這個實體類型。

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

參數

entityType
IMutableEntityType

實體類型。

property
IMutableProperty

要編制索引的屬性。

傳回

新建立的索引。

適用於