SqlServerModelExtensions.SetValueGenerationStrategy Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
SetValueGenerationStrategy(IMutableModel, Nullable<SqlServerValueGenerationStrategy>) |
Sets the SqlServerValueGenerationStrategy to use for properties of keys in the model that don't have a strategy explicitly set. |
SetValueGenerationStrategy(IConventionModel, Nullable<SqlServerValueGenerationStrategy>, Boolean) |
Sets the SqlServerValueGenerationStrategy to use for properties of keys in the model that don't have a strategy explicitly set. |
SetValueGenerationStrategy(IMutableModel, Nullable<SqlServerValueGenerationStrategy>)
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
Sets the SqlServerValueGenerationStrategy to use for properties of keys in the model that don't have a strategy explicitly set.
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))
Parameters
- model
- IMutableModel
The model.
The value to set.
Applies to
SetValueGenerationStrategy(IConventionModel, Nullable<SqlServerValueGenerationStrategy>, Boolean)
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
- Source:
- SqlServerModelExtensions.cs
Sets the SqlServerValueGenerationStrategy to use for properties of keys in the model that don't have a strategy explicitly set.
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)
Parameters
- model
- IConventionModel
The model.
The value to set.
- fromDataAnnotation
- Boolean
Indicates whether the configuration was specified using a data annotation.
Returns
The configured value.
Applies to
Entity Framework