Table of Contents

Class FailValidationRule

Namespace
The.Values
Assembly
Instagile.dll

Validation rule which always fails.

public sealed class FailValidationRule : IValidationRule
Inheritance
FailValidationRule
Implements
Inherited Members

Remarks

This is useful for when there is a condition on the scope for checking entity level rather than field level validations

Constructors

FailValidationRule(string, ValidationScope)

public FailValidationRule(string message, ValidationScope scope)

Parameters

message string
scope ValidationScope

Properties

IsAsyncRule

public bool IsAsyncRule { get; }

Property Value

bool

Message

public string Message { get; }

Property Value

string

Scope

public ValidationScope Scope { get; }

Property Value

ValidationScope

Methods

Evaluate(IValidatable)

public ValidationResult Evaluate(IValidatable subject)

Parameters

subject IValidatable

Returns

ValidationResult

EvaluateAsync(IValidatable)

public Task<ValidationResult> EvaluateAsync(IValidatable subject)

Parameters

subject IValidatable

Returns

Task<ValidationResult>