Condividi tramite


MigrationsSqlGenerator.UniqueConstraint Metodo

Definizione

Genera un frammento SQL per un vincolo univoco di un AddUniqueConstraintOperationoggetto .

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

Parametri

operation
AddUniqueConstraintOperation

Operazione.

model
IModel

Modello di destinazione che può essere null se le operazioni esistono senza un modello.

builder
MigrationCommandListBuilder

Generatore di comandi da usare per aggiungere il frammento SQL.

Si applica a