ModelValidator Class
Provides a base class for implementing validation logic.
Assembly: System.Web (in System.Web.dll)
System.Web.ModelBinding::ModelValidator
System.Web.ModelBinding::DataAnnotationsModelValidator
System.Web.ModelBinding::ValidatableObjectAdapter
| Name | Description | |
|---|---|---|
![]() | ModelValidator(ModelMetadata^, ModelBindingExecutionContext^) | Initializes a new instance of the ModelValidator class. |
| Name | Description | |
|---|---|---|
![]() | IsRequired | When implemented in a derived class, gets a value that indicates whether the model is required. |
![]() | Metadata | When implemented in a derived class, gets the metadata for the model validator. |
![]() | ModelBindingExecutionContext | When implemented in a derived class, gets the execution context. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object^) | Determines whether the specified object is equal to the current object.(Inherited from Object.) |
![]() | Finalize() | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.) |
![]() | GetHashCode() | Serves as the default hash function. (Inherited from Object.) |
![]() ![]() | GetModelValidator(ModelMetadata^, ModelBindingExecutionContext^) | Returns a composite model validator for the model. |
![]() | GetType() | |
![]() | MemberwiseClone() | |
![]() | ToString() | Returns a string that represents the current object.(Inherited from Object.) |
![]() | Validate(Object^) | When implemented in a derived class, validates the object. |
Available since 4.5
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.




