語言

SqlServerIndexBuilderExtensions.CanSetIsCreatedOnline 方法

定義

回傳一個值,表示在針對 SQL Server 時,索引是否能設定線上選項。

public static bool CanSetIsCreatedOnline(this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder indexBuilder, bool? createdOnline, bool fromDataAnnotation = false);
static member CanSetIsCreatedOnline : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder * Nullable<bool> * bool -> bool
<Extension()>
Public Function CanSetIsCreatedOnline (indexBuilder As IConventionIndexBuilder, createdOnline As Nullable(Of Boolean), Optional fromDataAnnotation As Boolean = false) As Boolean

參數

indexBuilder
IConventionIndexBuilder

正在設定索引的建置者。

createdOnline
Nullable<Boolean>

一個表示該指數是否以線上選項建立的數值。

fromDataAnnotation
Boolean

表示配置是否以資料註解方式指定。

傳回

如果設定是套用,則使用同一個建構者實例, null 否則。

備註

更多資訊與範例請參閱「建模實體類型與關係」,以及「使用 EF Core 存取 SQL Server 與 Azure SQL 資料庫」。

適用於