共用方式為


TableNameFromDbSetConvention 類別

定義

根據屬性名稱設定資料表名稱的 DbSet<TEntity> 慣例。

public class TableNameFromDbSetConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeBaseTypeChangedConvention
public class TableNameFromDbSetConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeBaseTypeChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IModelFinalizingConvention
public class TableNameFromDbSetConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeAnnotationChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeBaseTypeChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IModelFinalizingConvention
type TableNameFromDbSetConvention = class
    interface IEntityTypeAddedConvention
    interface IConvention
    interface IEntityTypeBaseTypeChangedConvention
type TableNameFromDbSetConvention = class
    interface IEntityTypeAddedConvention
    interface IConvention
    interface IEntityTypeBaseTypeChangedConvention
    interface IModelFinalizingConvention
type TableNameFromDbSetConvention = class
    interface IEntityTypeAddedConvention
    interface IConvention
    interface IEntityTypeBaseTypeChangedConvention
    interface IEntityTypeAnnotationChangedConvention
    interface IModelFinalizingConvention
Public Class TableNameFromDbSetConvention
Implements IEntityTypeAddedConvention, IEntityTypeBaseTypeChangedConvention
Public Class TableNameFromDbSetConvention
Implements IEntityTypeAddedConvention, IEntityTypeBaseTypeChangedConvention, IModelFinalizingConvention
Public Class TableNameFromDbSetConvention
Implements IEntityTypeAddedConvention, IEntityTypeAnnotationChangedConvention, IEntityTypeBaseTypeChangedConvention, IModelFinalizingConvention
繼承
TableNameFromDbSetConvention
實作

備註

如需詳細資訊和範例,請參閱 模型建置慣例

建構函式

TableNameFromDbSetConvention(ProviderConventionSetBuilderDependencies, RelationalConventionSetBuilderDependencies)

建立 TableNameFromDbSetConvention 的新執行個體。

屬性

Dependencies

此服務的相依性。

RelationalDependencies

此服務的關聯式提供者特定相依性。

方法

ProcessEntityTypeAdded(IConventionEntityTypeBuilder, IConventionContext<IConventionEntityTypeBuilder>)

在實體類型新增至模型之後呼叫。

ProcessEntityTypeAnnotationChanged(IConventionEntityTypeBuilder, String, IConventionAnnotation, IConventionAnnotation, IConventionContext<IConventionAnnotation>)

在實體類型上變更批註之後呼叫。

ProcessEntityTypeBaseTypeChanged(IConventionEntityTypeBuilder, IConventionEntityType, IConventionEntityType, IConventionContext<IConventionEntityType>)

在實體類型的基底類型變更之後呼叫。

ProcessModelFinalizing(IConventionModelBuilder, IConventionContext<IConventionModelBuilder>)

當模型完成時呼叫。

適用於