Exemple #1
0
 internal override void Validate(ModalDataInputForm form)
 {
     if (this.Value.Length < MinLength)
     {
         throw new ArgumentException($"The minimum length is {MinLength}");
     }
     if (MaxLength >= 0 && this.Value.Length > MaxLength)
     {
         throw new ArgumentException($"The maximum length is {MaxLength}");
     }
     this.Validator?.Invoke(this.Value, form);
 }
Exemple #2
0
 internal override void Validate(ModalDataInputForm form)
 {
     if (this.Value < Min)
     {
         throw new ArgumentException($"The minimum value is {Max}");
     }
     if (this.Value > Max)
     {
         throw new ArgumentException($"The maximum value is {Max}");
     }
     this.Validator?.Invoke(this.Value, form);
 }
Exemple #3
0
 internal abstract void Validate(ModalDataInputForm form);
Exemple #4
0
 internal override void Validate(ModalDataInputForm form)
 {
     this.Validator?.Invoke(this.Value, form);
 }