Share via


ModelAttributes.GetAttributesForProperty Méthode

Définition

Surcharges

GetAttributesForProperty(Type, PropertyInfo)

Obtient les attributs pour le donné property.

GetAttributesForProperty(Type, PropertyInfo, Type)

Obtient les attributs pour le donné property avec le spécifié modelType.

GetAttributesForProperty(Type, PropertyInfo)

Source:
ModelAttributes.cs
Source:
ModelAttributes.cs

Obtient les attributs pour le donné property.

public:
 static Microsoft::AspNetCore::Mvc::ModelBinding::ModelAttributes ^ GetAttributesForProperty(Type ^ type, System::Reflection::PropertyInfo ^ property);
public static Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes GetAttributesForProperty (Type type, System.Reflection.PropertyInfo property);
static member GetAttributesForProperty : Type * System.Reflection.PropertyInfo -> Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes
Public Shared Function GetAttributesForProperty (type As Type, property As PropertyInfo) As ModelAttributes

Paramètres

type
Type

dans Type lequel l’appelant a trouvé property.

property
PropertyInfo

PropertyInfo pour lequel les attributs doivent être résolus.

Retours

Une ModelAttributes instance avec les attributs de la propriété et de son Type.

S’applique à

GetAttributesForProperty(Type, PropertyInfo, Type)

Source:
ModelAttributes.cs

Obtient les attributs pour le donné property avec le spécifié modelType.

public:
 static Microsoft::AspNetCore::Mvc::ModelBinding::ModelAttributes ^ GetAttributesForProperty(Type ^ containerType, System::Reflection::PropertyInfo ^ property, Type ^ modelType);
public static Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes GetAttributesForProperty (Type containerType, System.Reflection.PropertyInfo property, Type modelType);
static member GetAttributesForProperty : Type * System.Reflection.PropertyInfo * Type -> Microsoft.AspNetCore.Mvc.ModelBinding.ModelAttributes
Public Shared Function GetAttributesForProperty (containerType As Type, property As PropertyInfo, modelType As Type) As ModelAttributes

Paramètres

containerType
Type

dans Type lequel l’appelant a trouvé property.

property
PropertyInfo

PropertyInfo pour lequel les attributs doivent être résolus.

modelType
Type

Type de modèle

Retours

Une ModelAttributes instance avec les attributs de la propriété et de son Type.

S’applique à