toTextInputFormatter method

List<TextInputFormatter> toTextInputFormatter()

TextInputLimitFormatter 转换为 List

Implementation

List<TextInputFormatter> toTextInputFormatter() {
  if (this == TextInputLimitFormatter.text) return [];
  final RegExp regExp = RegExp(allRegExp[this]!);
  return [FilteringTextInputFormatter.allow(regExp)];
}