Class BaseValidatorFactory
A factory service that gets instances of Validator<TValidated>.
Inheritance
System.Object
BaseValidatorFactory
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: CSF.Validation
Assembly: CSF.Validation.dll
Syntax
public class BaseValidatorFactory : IGetsBaseValidator
Constructors
| Improve this Doc View SourceBaseValidatorFactory(IGetsManifestFromBuilder, IGetsValidatorFromManifest)
Initialises a new instance of BaseValidatorFactory.
Declaration
public BaseValidatorFactory(IGetsManifestFromBuilder manifestFromBuilderProvider, IGetsValidatorFromManifest validatorFromManifestFactory)
Parameters
Type | Name | Description |
---|---|---|
IGetsManifestFromBuilder | manifestFromBuilderProvider | A validatio- manifest-from-builder provider. |
IGetsValidatorFromManifest | validatorFromManifestFactory | A validator-from-manifest factory. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | If any parameter is null. |
Methods
| Improve this Doc View SourceGetValidator(ValidationManifest)
Gets a validator from a validation manifest.
Declaration
public IValidator GetValidator(ValidationManifest manifest)
Parameters
Type | Name | Description |
---|---|---|
ValidationManifest | manifest | The validation manifest. |
Returns
Type | Description |
---|---|
IValidator | The validator. |
GetValidator<TValidated>(IBuildsValidator<TValidated>)
Gets a strongly-typed generic validator, from a validator builder instance.
Declaration
public IValidator<TValidated> GetValidator<TValidated>(IBuildsValidator<TValidated> builder)
Parameters
Type | Name | Description |
---|---|---|
IBuildsValidator<TValidated> | builder | The validator builder. |
Returns
Type | Description |
---|---|
IValidator<TValidated> | The validator. |
Type Parameters
Name | Description |
---|---|
TValidated | The validated type. |