FilteringTextInputFormatter.deny constructor Null safety

FilteringTextInputFormatter.deny(
  1. Pattern filterPattern,
  2. {String replacementString: ''}
)

Creates a formatter that blocks characters matching a pattern.

The filterPattern and replacementString arguments must not be null.

Implementation

FilteringTextInputFormatter.deny(
  this.filterPattern, {
  this.replacementString = '',
}) : assert(filterPattern != null),
     assert(replacementString != null),
     allow = false;