共用方式為


SqlServerModelExtensions.SetValueGenerationStrategy 方法

定義

多載

SetValueGenerationStrategy(IMutableModel, Nullable<SqlServerValueGenerationStrategy>)

SqlServerValueGenerationStrategy設定要用於模型中未明確設定策略之索引鍵屬性的 。

SetValueGenerationStrategy(IConventionModel, Nullable<SqlServerValueGenerationStrategy>, Boolean)

SqlServerValueGenerationStrategy設定要用於模型中未明確設定策略之索引鍵屬性的 。

SetValueGenerationStrategy(IMutableModel, Nullable<SqlServerValueGenerationStrategy>)

來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs

SqlServerValueGenerationStrategy設定要用於模型中未明確設定策略之索引鍵屬性的 。

public static void SetValueGenerationStrategy (this Microsoft.EntityFrameworkCore.Metadata.IMutableModel model, Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy? value);
static member SetValueGenerationStrategy : Microsoft.EntityFrameworkCore.Metadata.IMutableModel * Nullable<Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy> -> unit
<Extension()>
Public Sub SetValueGenerationStrategy (model As IMutableModel, value As Nullable(Of SqlServerValueGenerationStrategy))

參數

model
IMutableModel

模型本身。

value
Nullable<SqlServerValueGenerationStrategy>

要設定的值。

適用於

SetValueGenerationStrategy(IConventionModel, Nullable<SqlServerValueGenerationStrategy>, Boolean)

來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs
來源:
SqlServerModelExtensions.cs

SqlServerValueGenerationStrategy設定要用於模型中未明確設定策略之索引鍵屬性的 。

public static void SetValueGenerationStrategy (this Microsoft.EntityFrameworkCore.Metadata.IConventionModel model, Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy? value, bool fromDataAnnotation = false);
public static Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy? SetValueGenerationStrategy (this Microsoft.EntityFrameworkCore.Metadata.IConventionModel model, Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy? value, bool fromDataAnnotation = false);
static member SetValueGenerationStrategy : Microsoft.EntityFrameworkCore.Metadata.IConventionModel * Nullable<Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy> * bool -> unit
static member SetValueGenerationStrategy : Microsoft.EntityFrameworkCore.Metadata.IConventionModel * Nullable<Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy> * bool -> Nullable<Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy>
<Extension()>
Public Sub SetValueGenerationStrategy (model As IConventionModel, value As Nullable(Of SqlServerValueGenerationStrategy), Optional fromDataAnnotation As Boolean = false)
<Extension()>
Public Function SetValueGenerationStrategy (model As IConventionModel, value As Nullable(Of SqlServerValueGenerationStrategy), Optional fromDataAnnotation As Boolean = false) As Nullable(Of SqlServerValueGenerationStrategy)

參數

model
IConventionModel

模型本身。

value
Nullable<SqlServerValueGenerationStrategy>

要設定的值。

fromDataAnnotation
Boolean

指出是否已使用資料批註指定組態。

傳回

已設定的值。

適用於