Compartir a través de


MigrationsSqlGenerator.PrimaryKeyConstraint Método

Definición

Genera un fragmento de SQL para una restricción de clave principal de .AddPrimaryKeyOperation

protected virtual void PrimaryKeyConstraint (Microsoft.EntityFrameworkCore.Migrations.Operations.AddPrimaryKeyOperation operation, Microsoft.EntityFrameworkCore.Metadata.IModel model, Microsoft.EntityFrameworkCore.Migrations.MigrationCommandListBuilder builder);
protected virtual void PrimaryKeyConstraint (Microsoft.EntityFrameworkCore.Migrations.Operations.AddPrimaryKeyOperation operation, Microsoft.EntityFrameworkCore.Metadata.IModel? model, Microsoft.EntityFrameworkCore.Migrations.MigrationCommandListBuilder builder);
abstract member PrimaryKeyConstraint : Microsoft.EntityFrameworkCore.Migrations.Operations.AddPrimaryKeyOperation * Microsoft.EntityFrameworkCore.Metadata.IModel * Microsoft.EntityFrameworkCore.Migrations.MigrationCommandListBuilder -> unit
override this.PrimaryKeyConstraint : Microsoft.EntityFrameworkCore.Migrations.Operations.AddPrimaryKeyOperation * Microsoft.EntityFrameworkCore.Metadata.IModel * Microsoft.EntityFrameworkCore.Migrations.MigrationCommandListBuilder -> unit
Protected Overridable Sub PrimaryKeyConstraint (operation As AddPrimaryKeyOperation, model As IModel, builder As MigrationCommandListBuilder)

Parámetros

operation
AddPrimaryKeyOperation

Operación.

model
IModel

Modelo de destino que puede ser null si las operaciones existen sin un modelo.

builder
MigrationCommandListBuilder

Generador de comandos que se va a usar para agregar el fragmento de SQL.

Se aplica a