Share via


RequiredPropertyAttributeConvention Classe

Definição

Uma convenção que configura as propriedades conforme necessário se elas tiverem o RequiredAttribute aplicado.

public class RequiredPropertyAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.PropertyAttributeConventionBase<System.ComponentModel.DataAnnotations.RequiredAttribute>
public class RequiredPropertyAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.PropertyAttributeConventionBase<System.ComponentModel.DataAnnotations.RequiredAttribute>, Microsoft.EntityFrameworkCore.Metadata.Conventions.IComplexPropertyAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IComplexPropertyFieldChangedConvention
type RequiredPropertyAttributeConvention = class
    inherit PropertyAttributeConventionBase<RequiredAttribute>
type RequiredPropertyAttributeConvention = class
    inherit PropertyAttributeConventionBase<RequiredAttribute>
    interface IComplexPropertyAddedConvention
    interface IConvention
    interface IComplexPropertyFieldChangedConvention
Public Class RequiredPropertyAttributeConvention
Inherits PropertyAttributeConventionBase(Of RequiredAttribute)
Public Class RequiredPropertyAttributeConvention
Inherits PropertyAttributeConventionBase(Of RequiredAttribute)
Implements IComplexPropertyAddedConvention, IComplexPropertyFieldChangedConvention
Herança
RequiredPropertyAttributeConvention
Implementações

Comentários

Consulte Convenções de criação de modelo para obter mais informações e exemplos.

Construtores

RequiredPropertyAttributeConvention(ProviderConventionSetBuilderDependencies)

Cria uma nova instância de RequiredPropertyAttributeConvention.

Propriedades

Dependencies

Dependências para esse serviço.

(Herdado de PropertyAttributeConventionBase<TAttribute>)

Métodos

ProcessComplexPropertyAdded(IConventionComplexPropertyBuilder, IConventionContext<IConventionComplexPropertyBuilder>)

Chamado depois que uma propriedade complexa é adicionada a um objeto semelhante a um tipo.

(Herdado de PropertyAttributeConventionBase<TAttribute>)
ProcessComplexPropertyFieldChanged(IConventionComplexPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

Chamado depois que o campo de backup de uma propriedade complexa é alterado.

(Herdado de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionComplexPropertyBuilder, RequiredAttribute, MemberInfo, IConventionContext)

Uma convenção que configura as propriedades conforme necessário se elas tiverem o RequiredAttribute aplicado.

ProcessPropertyAdded(IConventionComplexPropertyBuilder, TAttribute, MemberInfo, IConventionContext)

Chamado depois que uma propriedade complexa é adicionada a um tipo com um atributo na propriedade ou campo CLR associado.

(Herdado de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionPropertyBuilder, IConventionContext<IConventionPropertyBuilder>)

Chamado depois que uma propriedade é adicionada ao tipo de entidade.

(Herdado de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionPropertyBuilder, RequiredAttribute, MemberInfo, IConventionContext)

Chamado depois que uma propriedade é adicionada ao tipo de entidade com um atributo na propriedade ou campo CLR associado.

ProcessPropertyAdded(IConventionPropertyBuilder, TAttribute, MemberInfo, IConventionContext)

Chamado depois que uma propriedade é adicionada ao tipo de entidade com um atributo na propriedade ou campo CLR associado.

(Herdado de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyFieldChanged(IConventionPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

Chamado depois que o campo de backup de uma propriedade é alterado.

(Herdado de PropertyAttributeConventionBase<TAttribute>)

Aplica-se a