Dela via


ClientValidatorCache.GetValidators Method

Definition

Gets the IClientModelValidator for the metadata from the cache, using the validatorProvider to create when needed.

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

Parameters

metadata
ModelMetadata

The ModelMetadata being validated.

validatorProvider
IClientModelValidatorProvider

The IClientModelValidatorProvider which will be used to create validators when needed.

Returns

The list of IClientModelValidators.

Applies to