C# Class FluentValidation.Validators.PropertyValidator

Inheritance: IPropertyValidator
Afficher le fichier Open project: JeremySkinner/FluentValidation Class Usage Examples

Méthodes publiques

Méthode Description
Validate ( PropertyValidatorContext context ) : IEnumerable
ValidateAsync ( PropertyValidatorContext context, CancellationToken cancellation ) : Task>

Méthodes protégées

Méthode Description
CreateValidationError ( PropertyValidatorContext context ) : ValidationFailure

Creates an error validation result for this validator.

IsValid ( PropertyValidatorContext context ) : bool
IsValidAsync ( PropertyValidatorContext context, CancellationToken cancellation ) : Task
PrepareMessageFormatterForValidationError ( PropertyValidatorContext context ) : void

Prepares the MessageFormatter of context for an upcoming ValidationFailure.

PropertyValidator ( Expression errorMessageResourceSelector ) : System.Threading
PropertyValidator ( string errorMessage ) : System.Threading
PropertyValidator ( string errorMessageResourceName, Type errorMessageResourceType ) : System.Threading

Private Methods

Méthode Description
BuildErrorMessage ( PropertyValidatorContext context ) : string

Method Details

CreateValidationError() protected méthode

Creates an error validation result for this validator.
protected CreateValidationError ( PropertyValidatorContext context ) : ValidationFailure
context PropertyValidatorContext The validator context
Résultat ValidationFailure

IsValid() protected abstract méthode

protected abstract IsValid ( PropertyValidatorContext context ) : bool
context PropertyValidatorContext
Résultat bool

IsValidAsync() protected méthode

protected IsValidAsync ( PropertyValidatorContext context, CancellationToken cancellation ) : Task
context PropertyValidatorContext
cancellation CancellationToken
Résultat Task

PrepareMessageFormatterForValidationError() protected méthode

Prepares the MessageFormatter of context for an upcoming ValidationFailure.
protected PrepareMessageFormatterForValidationError ( PropertyValidatorContext context ) : void
context PropertyValidatorContext The validator context
Résultat void

PropertyValidator() protected méthode

protected PropertyValidator ( Expression errorMessageResourceSelector ) : System.Threading
errorMessageResourceSelector Expression
Résultat System.Threading

PropertyValidator() protected méthode

protected PropertyValidator ( string errorMessage ) : System.Threading
errorMessage string
Résultat System.Threading

PropertyValidator() protected méthode

protected PropertyValidator ( string errorMessageResourceName, Type errorMessageResourceType ) : System.Threading
errorMessageResourceName string
errorMessageResourceType System.Type
Résultat System.Threading

Validate() public méthode

public Validate ( PropertyValidatorContext context ) : IEnumerable
context PropertyValidatorContext
Résultat IEnumerable

ValidateAsync() public méthode

public ValidateAsync ( PropertyValidatorContext context, CancellationToken cancellation ) : Task>
context PropertyValidatorContext
cancellation CancellationToken
Résultat Task>