StringLengthAttributeConvention Classe

Définition

Convention qui configure la longueur maximale en fonction de la StringLengthAttribute valeur appliquée à la propriété .

public class StringLengthAttributeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.PropertyAttributeConventionBase<System.ComponentModel.DataAnnotations.StringLengthAttribute>
type StringLengthAttributeConvention = class
    inherit PropertyAttributeConventionBase<StringLengthAttribute>
Public Class StringLengthAttributeConvention
Inherits PropertyAttributeConventionBase(Of StringLengthAttribute)
Héritage

Remarques

Pour plus d’informations et d’exemples, consultez Conventions de génération de modèles.

Constructeurs

StringLengthAttributeConvention(ProviderConventionSetBuilderDependencies)

Crée une instance de StringLengthAttributeConvention.

Propriétés

Dependencies

Dépendances pour ce service.

(Hérité de PropertyAttributeConventionBase<TAttribute>)

Méthodes

ProcessComplexPropertyAdded(IConventionComplexPropertyBuilder, IConventionContext<IConventionComplexPropertyBuilder>)

Appelée après l’ajout d’une propriété complexe à un objet de type.

(Hérité de PropertyAttributeConventionBase<TAttribute>)
ProcessComplexPropertyFieldChanged(IConventionComplexPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

Appelé après la modification du champ de sauvegarde d’une propriété complexe.

(Hérité de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionComplexPropertyBuilder, TAttribute, MemberInfo, IConventionContext)

Appelée après l’ajout d’une propriété complexe à un type avec un attribut sur la propriété ou le champ CLR associé.

(Hérité de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionPropertyBuilder, IConventionContext<IConventionPropertyBuilder>)

Appelée après l’ajout d’une propriété au type d’entité.

(Hérité de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyAdded(IConventionPropertyBuilder, StringLengthAttribute, MemberInfo, IConventionContext)

Appelée après l’ajout d’une propriété au type d’entité avec un attribut sur la propriété ou le champ CLR associé.

ProcessPropertyAdded(IConventionPropertyBuilder, TAttribute, MemberInfo, IConventionContext)

Appelée après l’ajout d’une propriété au type d’entité avec un attribut sur la propriété ou le champ CLR associé.

(Hérité de PropertyAttributeConventionBase<TAttribute>)
ProcessPropertyFieldChanged(IConventionPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

Appelé après la modification du champ de sauvegarde d’une propriété.

(Hérité de PropertyAttributeConventionBase<TAttribute>)

S’applique à