RegexModel constructor

RegexModel({
  1. required String title,
  2. RegExp? regExp,
  3. bool test(
    1. String value
    )?,
  4. IconData? iconTrue,
  5. IconData? iconFalse,
  6. Color? colorTrue,
  7. Color? colorFalse,
  8. Color? textColorTrue,
  9. Color? textColorFalse,
  10. TextStyle? textStyle,
})

Creates a rule from a regExp or a test function.

Implementation

RegexModel({
  required this.title,
  this.regExp,
  this.test,
  this.iconTrue,
  this.iconFalse,
  this.colorTrue,
  this.colorFalse,
  this.textColorTrue,
  this.textColorFalse,
  this.textStyle,
}) : assert(regExp != null || test != null, 'Pass a regExp or a test');