NotMappedTypeAttributeConvention 类

定义

忽略具有 NotMappedAttribute的实体类型的约定。

public class NotMappedTypeAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.TypeAttributeConventionBase<System.ComponentModel.DataAnnotations.Schema.NotMappedAttribute>
type NotMappedTypeAttributeConvention = class
    inherit TypeAttributeConventionBase<NotMappedAttribute>
Public Class NotMappedTypeAttributeConvention
Inherits TypeAttributeConventionBase(Of NotMappedAttribute)
继承
NotMappedTypeAttributeConvention

注解

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

构造函数

NotMappedTypeAttributeConvention(ProviderConventionSetBuilderDependencies)

创建 NotMappedTypeAttributeConvention 的新实例。

属性

Dependencies

此服务的依赖项。

(继承自 TypeAttributeConventionBase<TAttribute>)

方法

ProcessComplexPropertyAdded(IConventionComplexPropertyBuilder, IConventionContext<IConventionComplexPropertyBuilder>)

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

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

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

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

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

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

在实体类型添加到模型(如果实体类型具有属性)之后调用。

ProcessEntityTypeAdded(IConventionEntityTypeBuilder, TAttribute, IConventionContext<IConventionEntityTypeBuilder>)

在实体类型添加到模型(如果实体类型具有属性)之后调用。

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

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

(继承自 TypeAttributeConventionBase<TAttribute>)

适用于