Class BulkValidator
- Namespace
- CloudyWing.FormValidators
- Assembly
- CloudyWing.FormValidators.dll
The bulk validator.
public class BulkValidator : Collection<IFormValidator>, IList<IFormValidator>, ICollection<IFormValidator>, IReadOnlyList<IFormValidator>, IReadOnlyCollection<IFormValidator>, IEnumerable<IFormValidator>, IList, ICollection, IEnumerable, IFormValidator
- Inheritance
-
BulkValidator
- Implements
- Inherited Members
Constructors
BulkValidator(Action<ValidatorConfiguration>, bool)
Initializes a new instance of the BulkValidator class.
public BulkValidator(Action<ValidatorConfiguration> configure, bool isStoppedIfFail = false)
Parameters
configureAction<ValidatorConfiguration>The configure.
isStoppedIfFailboolif set to
true[is stopped if fail].
BulkValidator(bool)
Initializes a new instance of the BulkValidator class.
public BulkValidator(bool isStoppedIfFail = false)
Parameters
isStoppedIfFailboolif set to
true[is stopped if fail].
Properties
ErrorMessage
Gets the error message, separated by br.
public string ErrorMessage { get; }
Property Value
- string
The error message.
ErrorMessageWithBR
Gets the error message, separated by br.
public string ErrorMessageWithBR { get; }
Property Value
- string
The error message separated by br.
ErrorMessageWithLF
Gets the error message, separated by \n.
public string ErrorMessageWithLF { get; }
Property Value
- string
The error message separated by
\n.
ErrorMessageWithNewLine
Gets the error message, separated by newlines.
public string ErrorMessageWithNewLine { get; }
Property Value
- string
The error message separated by new line.
ErrorMessages
Gets the error messages.
public IReadOnlyCollection<string> ErrorMessages { get; }
Property Value
- IReadOnlyCollection<string>
The error messages.
IsStoppedIfFail
Gets a value indicating whether this instance is stopped if fail.
public bool IsStoppedIfFail { get; }
Property Value
- bool
trueif this instance is stopped if fail; otherwise,false.
IsValid
Returns true if ... is valid.
public bool IsValid { get; }
Property Value
- bool
trueif this instance is valid; otherwise,false.
Methods
Validate()
Validates this instance.
public bool Validate()
Returns
- bool
The validation result.