Table of Contents

Interface IRelationalAnnotationProvider

Namespace
Microsoft.EntityFrameworkCore.Metadata
Assembly
Microsoft.EntityFrameworkCore.Relational.dll

A service typically implemented by database providers that gives access to annotations used by relational EF Core components on various elements of the IRelationalModel.

public interface IRelationalAnnotationProvider

Remarks

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.

See Implementation of database providers and extensions for more information and examples.

Methods

For(ICheckConstraint, bool)

Gets provider-specific annotations for the given ICheckConstraint.

IEnumerable<IAnnotation> For(ICheckConstraint checkConstraint, bool designTime)

Parameters

checkConstraint ICheckConstraint

The check constraint.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IColumn, bool)

Gets provider-specific annotations for the given IColumn.

IEnumerable<IAnnotation> For(IColumn column, bool designTime)

Parameters

column IColumn

The column.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IForeignKeyConstraint, bool)

Gets provider-specific annotations for the given IForeignKeyConstraint.

IEnumerable<IAnnotation> For(IForeignKeyConstraint foreignKey, bool designTime)

Parameters

foreignKey IForeignKeyConstraint

The foreign key.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IFunctionColumn, bool)

Gets provider-specific annotations for the given IFunctionColumn.

IEnumerable<IAnnotation> For(IFunctionColumn column, bool designTime)

Parameters

column IFunctionColumn

The column.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IRelationalModel, bool)

Gets provider-specific annotations for the given IRelationalModel.

IEnumerable<IAnnotation> For(IRelationalModel model, bool designTime)

Parameters

model IRelationalModel

The database model.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(ISequence, bool)

Gets provider-specific annotations for the given ISequence.

IEnumerable<IAnnotation> For(ISequence sequence, bool designTime)

Parameters

sequence ISequence

The sequence.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(ISqlQuery, bool)

Gets provider-specific annotations for the given ISqlQuery.

IEnumerable<IAnnotation> For(ISqlQuery sqlQuery, bool designTime)

Parameters

sqlQuery ISqlQuery

The SQL query.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(ISqlQueryColumn, bool)

Gets provider-specific annotations for the given ISqlQueryColumn.

IEnumerable<IAnnotation> For(ISqlQueryColumn column, bool designTime)

Parameters

column ISqlQueryColumn

The column.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IStoreFunction, bool)

Gets provider-specific annotations for the given IStoreFunction.

IEnumerable<IAnnotation> For(IStoreFunction function, bool designTime)

Parameters

function IStoreFunction

The function.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IStoreStoredProcedure, bool)

Gets provider-specific annotations for the given IStoreStoredProcedure.

IEnumerable<IAnnotation> For(IStoreStoredProcedure storedProcedure, bool designTime)

Parameters

storedProcedure IStoreStoredProcedure

The stored procedure.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IStoreStoredProcedureParameter, bool)

Gets provider-specific annotations for the given IStoreStoredProcedureParameter.

IEnumerable<IAnnotation> For(IStoreStoredProcedureParameter parameter, bool designTime)

Parameters

parameter IStoreStoredProcedureParameter

The parameter.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IStoreStoredProcedureResultColumn, bool)

Gets provider-specific annotations for the given IStoreStoredProcedureResultColumn.

IEnumerable<IAnnotation> For(IStoreStoredProcedureResultColumn column, bool designTime)

Parameters

column IStoreStoredProcedureResultColumn

The result column.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(ITable, bool)

Gets provider-specific annotations for the given ITable.

IEnumerable<IAnnotation> For(ITable table, bool designTime)

Parameters

table ITable

The table.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(ITableIndex, bool)

Gets provider-specific annotations for the given ITableIndex.

IEnumerable<IAnnotation> For(ITableIndex index, bool designTime)

Parameters

index ITableIndex

The index.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(ITrigger, bool)

Gets provider-specific annotations for the given Microsoft.EntityFrameworkCore.Metadata.ITrigger.

IEnumerable<IAnnotation> For(ITrigger trigger, bool designTime)

Parameters

trigger ITrigger

The trigger.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IUniqueConstraint, bool)

Gets provider-specific annotations for the given IUniqueConstraint.

IEnumerable<IAnnotation> For(IUniqueConstraint constraint, bool designTime)

Parameters

constraint IUniqueConstraint

The unique constraint.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IView, bool)

Gets provider-specific annotations for the given IView.

IEnumerable<IAnnotation> For(IView view, bool designTime)

Parameters

view IView

The view.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.

For(IViewColumn, bool)

Gets provider-specific annotations for the given IViewColumn.

IEnumerable<IAnnotation> For(IViewColumn column, bool designTime)

Parameters

column IViewColumn

The column.

designTime bool

Whether the model should contain design-time configuration.

Returns

IEnumerable<IAnnotation>

The annotations.