parse method

  1. @override
int parse(
  1. String input
)
override

Parses input and returns the numeric value.

Throws FormatException when input cannot be parsed by this codec.

Implementation

@override
int parse(String input) {
  final normalized = input.replaceAll('兩', '两');
  return zh.ChineseYearCodec(suffix: suffix).parse(normalized);
}