SqlServerModelExtensions.GetValueGenerationStrategy Method

Definition

Overloads

GetValueGenerationStrategy(IModel)

Returns the SqlServerValueGenerationStrategy to use for properties of keys in the model, unless the property has a strategy explicitly set.

GetValueGenerationStrategy(IReadOnlyModel)

Returns the SqlServerValueGenerationStrategy to use for properties of keys in the model, unless the property has a strategy explicitly set.

GetValueGenerationStrategy(IModel)

Source:
SqlServerModelExtensions.cs
Source:
SqlServerModelExtensions.cs
Source:
SqlServerModelExtensions.cs

Returns the SqlServerValueGenerationStrategy to use for properties of keys in the model, unless the property has a strategy explicitly set.

C#
public static Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy? GetValueGenerationStrategy (this Microsoft.EntityFrameworkCore.Metadata.IModel model);

Parameters

model
IModel

The model.

Returns

The default SqlServerValueGenerationStrategy.

Applies to

Entity Framework Core 5.0 och andra versioner
Produkt Versioner
Entity Framework Core 3.0, 3.1, 5.0

GetValueGenerationStrategy(IReadOnlyModel)

Source:
SqlServerModelExtensions.cs
Source:
SqlServerModelExtensions.cs
Source:
SqlServerModelExtensions.cs
Source:
SqlServerModelExtensions.cs

Returns the SqlServerValueGenerationStrategy to use for properties of keys in the model, unless the property has a strategy explicitly set.

C#
public static Microsoft.EntityFrameworkCore.Metadata.SqlServerValueGenerationStrategy? GetValueGenerationStrategy (this Microsoft.EntityFrameworkCore.Metadata.IReadOnlyModel model);

Parameters

model
IReadOnlyModel

The model.

Returns

The default SqlServerValueGenerationStrategy.

Applies to

Entity Framework Core 9.0 och andra versioner
Produkt Versioner
Entity Framework Core 6.0, 7.0, 8.0, 9.0