閱讀英文版本

分享方式:


RelationalTableAttributeConvention 類別

定義

根據套用 TableAttribute 的 ,設定實體類型的資料表名稱和架構的慣例。

C#
public class RelationalTableAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.EntityTypeAttributeConventionBase<System.ComponentModel.DataAnnotations.Schema.TableAttribute>
C#
public class RelationalTableAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.TypeAttributeConventionBase<System.ComponentModel.DataAnnotations.Schema.TableAttribute>
繼承
RelationalTableAttributeConvention
繼承
RelationalTableAttributeConvention

備註

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

建構函式

屬性

Dependencies

此服務的相依性。

(繼承來源 EntityTypeAttributeConventionBase<TAttribute>)
Dependencies

此服務的相依性。

(繼承來源 TypeAttributeConventionBase<TAttribute>)
RelationalDependencies

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

方法

ProcessComplexPropertyAdded(IConventionComplexPropertyBuilder, IConventionContext<IConventionComplexPropertyBuilder>)

在複雜屬性新增至類似型別的物件之後呼叫。

(繼承來源 TypeAttributeConventionBase<TAttribute>)
ProcessComplexTypeAdded(IConventionComplexTypeBuilder, TAttribute, IConventionContext)

如果模型具有 屬性,請在將複雜類型新增至模型之後呼叫。

(繼承來源 TypeAttributeConventionBase<TAttribute>)
ProcessEntityTypeAdded(IConventionEntityTypeBuilder, IConventionContext<IConventionEntityTypeBuilder>)

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

(繼承來源 EntityTypeAttributeConventionBase<TAttribute>)
ProcessEntityTypeAdded(IConventionEntityTypeBuilder, IConventionContext<IConventionEntityTypeBuilder>)

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

(繼承來源 TypeAttributeConventionBase<TAttribute>)
ProcessEntityTypeAdded(IConventionEntityTypeBuilder, TableAttribute, IConventionContext<IConventionEntityTypeBuilder>)

如果實體類型具有屬性,請在模型新增實體類型之後呼叫。

ProcessEntityTypeAdded(IConventionEntityTypeBuilder, TAttribute, IConventionContext<IConventionEntityTypeBuilder>)

如果實體類型具有屬性,請在模型新增實體類型之後呼叫。

(繼承來源 EntityTypeAttributeConventionBase<TAttribute>)
ProcessEntityTypeAdded(IConventionEntityTypeBuilder, TAttribute, IConventionContext<IConventionEntityTypeBuilder>)

如果實體類型具有屬性,請在模型新增實體類型之後呼叫。

(繼承來源 TypeAttributeConventionBase<TAttribute>)
ReplaceWithEntityType(IConventionComplexTypeBuilder, Nullable<Boolean>)

嘗試以實體類型取代複雜類型。

(繼承來源 TypeAttributeConventionBase<TAttribute>)

適用於

產品 版本
Entity Framework Core 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0