语言

DeleteBehaviorAttributeConvention 类

定义

基于对属性应用的删除行为配置删除行为的 DeleteBehaviorAttribute 约定。

[System.Runtime.CompilerServices.Nullable(new System.Byte[] { 0, 1 })]
public class DeleteBehaviorAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.PropertyAttributeConventionBase<Microsoft.EntityFrameworkCore.DeleteBehaviorAttribute>, Microsoft.EntityFrameworkCore.Metadata.Conventions.IComplexPropertyAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IForeignKeyPrincipalEndChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IModelFinalizingConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.INavigationAddedConvention
public class DeleteBehaviorAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.PropertyAttributeConventionBase<Microsoft.EntityFrameworkCore.DeleteBehaviorAttribute>, Microsoft.EntityFrameworkCore.Metadata.Conventions.IForeignKeyPrincipalEndChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IModelFinalizingConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.INavigationAddedConvention
[<System.Runtime.CompilerServices.Nullable(new System.Byte[] { 0, 1 })>]
type DeleteBehaviorAttributeConvention = class
    inherit PropertyAttributeConventionBase<DeleteBehaviorAttribute>
    interface INavigationAddedConvention
    interface IConvention
    interface IForeignKeyPrincipalEndChangedConvention
    interface IComplexPropertyAddedConvention
    interface IModelFinalizingConvention
type DeleteBehaviorAttributeConvention = class
    inherit PropertyAttributeConventionBase<DeleteBehaviorAttribute>
    interface INavigationAddedConvention
    interface IConvention
    interface IForeignKeyPrincipalEndChangedConvention
    interface IModelFinalizingConvention
Public Class DeleteBehaviorAttributeConvention
Inherits PropertyAttributeConventionBase(Of DeleteBehaviorAttribute)
Implements IComplexPropertyAddedConvention, IForeignKeyPrincipalEndChangedConvention, IModelFinalizingConvention, INavigationAddedConvention
Public Class DeleteBehaviorAttributeConvention
Inherits PropertyAttributeConventionBase(Of DeleteBehaviorAttribute)
Implements IForeignKeyPrincipalEndChangedConvention, IModelFinalizingConvention, INavigationAddedConvention
继承
特性
实现

注解

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

构造函数

名称 说明
DeleteBehaviorAttributeConvention(ProviderConventionSetBuilderDependencies)

初始化 DeleteBehaviorAttributeConvention 类的新实例。

属性

名称 说明
Dependencies

此服务的依赖项。

(继承自 PropertyAttributeConventionBase<TAttribute>)

方法

名称 说明
ProcessComplexPropertyAdded(IConventionComplexPropertyBuilder, IConventionContext<IConventionComplexPropertyBuilder>)

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

(继承自 PropertyAttributeConventionBase<TAttribute>)
ProcessComplexPropertyFieldChanged(IConventionComplexPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

在复杂属性的后盾字段更改后调用。

(继承自 PropertyAttributeConventionBase<TAttribute>)
ProcessForeignKeyPrincipalEndChanged(IConventionForeignKeyBuilder, IConventionContext<IConventionForeignKeyBuilder>)

在外键的主体结束更改后调用。

ProcessModelFinalizing(IConventionModelBuilder, IConventionContext<IConventionModelBuilder>)

在完成模型时调用。

ProcessNavigationAdded(IConventionNavigationBuilder, IConventionContext<IConventionNavigationBuilder>)

在将导航添加到实体类型后调用。

ProcessPropertyAdded(IConventionComplexPropertyBuilder, DeleteBehaviorAttribute, MemberInfo, IConventionContext)

在将复杂属性添加到具有关联 CLR 属性或字段的属性的类型后调用。

ProcessPropertyAdded(IConventionComplexPropertyBuilder, TAttribute, MemberInfo, IConventionContext)

在将复杂属性添加到具有关联 CLR 属性或字段的属性的类型后调用。

(继承自 PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionPropertyBuilder, DeleteBehaviorAttribute, MemberInfo, IConventionContext)

在将属性添加到实体类型后调用,该实体类型具有关联的 CLR 属性或字段上的属性。

ProcessPropertyAdded(IConventionPropertyBuilder, IConventionContext<IConventionPropertyBuilder>)

在将属性添加到实体类型后调用。

(继承自 PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionPropertyBuilder, TAttribute, MemberInfo, IConventionContext)

在将属性添加到实体类型后调用,该实体类型具有关联的 CLR 属性或字段上的属性。

(继承自 PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyFieldChanged(IConventionPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

在属性的后盾字段更改后调用。

(继承自 PropertyAttributeConventionBase<TAttribute>)

适用于