Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
GetValidators Method (ModelMetadata, ControllerContext, IEnumerable(Attribute))

AssociatedValidatorProvider.GetValidators Method (ModelMetadata, ControllerContext, IEnumerable(Attribute))

Gets the validators for the model using the metadata, the controller context, and a list of attributes.

Namespace:  System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)

abstract GetValidators : 
        metadata:ModelMetadata * 
        context:ControllerContext * 
        attributes:IEnumerable<Attribute> -> IEnumerable<ModelValidator> 

Parameters

metadata
Type: System.Web.Mvc.ModelMetadata

The metadata.

context
Type: System.Web.Mvc.ControllerContext

The controller context.

attributes
Type: System.Collections.Generic.IEnumerable(Attribute)

The list of attributes.

Return Value

Type: System.Collections.Generic.IEnumerable(ModelValidator)
The validators for the model.
Show:
© 2015 Microsoft