Allows the combination of several validator providers into a single validator provider.
Remarks
This class can be used to unify instances of IValidatorProvider into a single one and provides several sources in order to retrieve IValidator instances.
Fields
Methods
Add(IValidatorProvider validatorProvider)
Add the validator provider to this composite validator provider.
Parameters
Name
Description
validatorProvider
The validator provider.
Exceptions
Name
Description
ArgumentNullException
If validatorProvider isnull.
Contains(IValidatorProvider validatorProvider)
Determines whether this composite validator provider contains the specified validator provider.
Parameters
Name
Description
validatorProvider
The validator provider.
Returns
true if this composite validator provider contains the specified validator; otherwise,false.
Exceptions
Name
Description
ArgumentNullException
The validatorProvider isnull.
GetValidator(Type targetType)
Gets a validator for the specified target type.
Parameters
Name
Description
targetType
The target type.
Returns
The IValidator for the specified type ornull if no validator is available for the specified type.
Exceptions
Name
Description
ArgumentNullException
The targetType isnull.
Remarks
If there are more than once validator provider and they retrieve more than once validator all of these will be aggregated into a single CompositeValidator.
Remove(IValidatorProvider validatorProvider)
Removes the validator provider from this composite validator provider.
Parameters
Name
Description
validatorProvider
The validator provider.
Exceptions
Name
Description
ArgumentNullException
If validatorProvider isnull.
Have a question about Catel? Use StackOverflow with the Catel tag!