Partager via


ValidatorCache.GetValidators(ModelMetadata, IModelValidatorProvider) Méthode

Définition

Obtenez les validateurs d’un modèle.

public:
 System::Collections::Generic::IReadOnlyList<Microsoft::AspNetCore::Mvc::ModelBinding::Validation::IModelValidator ^> ^ GetValidators(Microsoft::AspNetCore::Mvc::ModelBinding::ModelMetadata ^ metadata, Microsoft::AspNetCore::Mvc::ModelBinding::Validation::IModelValidatorProvider ^ validatorProvider);
public System.Collections.Generic.IReadOnlyList<Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidator> GetValidators (Microsoft.AspNetCore.Mvc.ModelBinding.ModelMetadata metadata, Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidatorProvider validatorProvider);
member this.GetValidators : Microsoft.AspNetCore.Mvc.ModelBinding.ModelMetadata * Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidatorProvider -> System.Collections.Generic.IReadOnlyList<Microsoft.AspNetCore.Mvc.ModelBinding.Validation.IModelValidator>
Public Function GetValidators (metadata As ModelMetadata, validatorProvider As IModelValidatorProvider) As IReadOnlyList(Of IModelValidator)

Paramètres

metadata
ModelMetadata

Métadonnées du modèle.

validatorProvider
IModelValidatorProvider

Fournisseur du validateur.

Retours

Liste des validateurs de modèle.

S’applique à