OwnedAttributeConvention 类

定义

一种约定,用于配置拥有 OwnedAttribute 的实体类型。

public class OwnedAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.TypeAttributeConventionBase<Microsoft.EntityFrameworkCore.OwnedAttribute>, Microsoft.EntityFrameworkCore.Metadata.Conventions.IComplexPropertyAddedConvention
type OwnedAttributeConvention = class
    inherit TypeAttributeConventionBase<OwnedAttribute>
    interface IComplexPropertyAddedConvention
    interface IConvention
Public Class OwnedAttributeConvention
Inherits TypeAttributeConventionBase(Of OwnedAttribute)
Implements IComplexPropertyAddedConvention
继承
实现

注解

有关详细信息和示例,请参阅 模型生成约定

构造函数

OwnedAttributeConvention(ProviderConventionSetBuilderDependencies)

创建 OwnedAttributeConvention 的新实例。

属性

Dependencies

此服务的依赖项。

(继承自 TypeAttributeConventionBase<TAttribute>)

方法

ProcessComplexPropertyAdded(IConventionComplexPropertyBuilder, IConventionContext<IConventionComplexPropertyBuilder>)

在将复杂属性添加到类似类型的对象后调用。

(继承自 TypeAttributeConventionBase<TAttribute>)
ProcessComplexTypeAdded(IConventionComplexTypeBuilder, OwnedAttribute, IConventionContext)

一种约定,用于配置拥有 OwnedAttribute 的实体类型。

ProcessComplexTypeAdded(IConventionComplexTypeBuilder, TAttribute, IConventionContext)

如果复杂类型具有 属性,则将其添加到模型后调用。

(继承自 TypeAttributeConventionBase<TAttribute>)
ProcessEntityTypeAdded(IConventionEntityTypeBuilder, IConventionContext<IConventionEntityTypeBuilder>)

在实体类型添加到模型后调用。

(继承自 TypeAttributeConventionBase<TAttribute>)
ProcessEntityTypeAdded(IConventionEntityTypeBuilder, OwnedAttribute, IConventionContext<IConventionEntityTypeBuilder>)

一种约定,用于配置拥有 OwnedAttribute 的实体类型。

ProcessEntityTypeAdded(IConventionEntityTypeBuilder, TAttribute, IConventionContext<IConventionEntityTypeBuilder>)

如果实体类型具有属性,则将其添加到模型后调用。

(继承自 TypeAttributeConventionBase<TAttribute>)
ReplaceWithEntityType(IConventionComplexTypeBuilder, Nullable<Boolean>)

尝试将复杂类型替换为实体类型。

(继承自 TypeAttributeConventionBase<TAttribute>)

适用于