Interface IMigrationsAnnotationProvider
- Namespace
- Microsoft.EntityFrameworkCore.Migrations
- Assembly
- Microsoft.EntityFrameworkCore.Relational.dll
A service typically implemented by database providers that gives access to annotations used by EF Core Migrations when generating removal operations for various elements of the IRelationalModel. The annotations stored in the relational model are provided by IRelationalAnnotationProvider.
The service lifetime is Singleton. This means a single instance is used by many Microsoft.EntityFrameworkCore.DbContext instances. The implementation must be thread-safe. This service cannot depend on services registered as Scoped.
public interface IMigrationsAnnotationProvider
Methods
ForRemove(ICheckConstraint)
Gets provider-specific Migrations annotations for the given ICheckConstraint when it is being removed.
IEnumerable<IAnnotation> ForRemove(ICheckConstraint checkConstraint)
Parameters
checkConstraintICheckConstraintThe check constraint.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(IColumn)
Gets provider-specific Migrations annotations for the given IColumn when it is being removed.
IEnumerable<IAnnotation> ForRemove(IColumn column)
Parameters
columnIColumnThe column.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(IForeignKeyConstraint)
Gets provider-specific Migrations annotations for the given IForeignKeyConstraint when it is being removed.
IEnumerable<IAnnotation> ForRemove(IForeignKeyConstraint foreignKey)
Parameters
foreignKeyIForeignKeyConstraintThe foreign key.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(IRelationalModel)
Gets provider-specific Migrations annotations for the given IRelationalModel when it is being altered.
IEnumerable<IAnnotation> ForRemove(IRelationalModel model)
Parameters
modelIRelationalModelThe database model.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(ISequence)
Gets provider-specific Migrations annotations for the given ISequence when it is being removed.
IEnumerable<IAnnotation> ForRemove(ISequence sequence)
Parameters
sequenceISequenceThe sequence.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(ITable)
Gets provider-specific Migrations annotations for the given ITable when it is being removed.
IEnumerable<IAnnotation> ForRemove(ITable table)
Parameters
tableITableThe table.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(ITableIndex)
Gets provider-specific Migrations annotations for the given ITableIndex when it is being removed.
IEnumerable<IAnnotation> ForRemove(ITableIndex index)
Parameters
indexITableIndexThe index.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(IUniqueConstraint)
Gets provider-specific Migrations annotations for the given IUniqueConstraint when it is being removed.
IEnumerable<IAnnotation> ForRemove(IUniqueConstraint constraint)
Parameters
constraintIUniqueConstraintThe unique constraint.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(IView)
Gets provider-specific annotations for the given IView when it is being removed.
IEnumerable<IAnnotation> ForRemove(IView view)
Parameters
viewIViewThe view.
Returns
- IEnumerable<IAnnotation>
The annotations.
ForRemove(IViewColumn)
Gets provider-specific annotations for the given IViewColumn when it is being removed.
IEnumerable<IAnnotation> ForRemove(IViewColumn column)
Parameters
columnIViewColumnThe column.
Returns
- IEnumerable<IAnnotation>
The annotations.