// CardinalExtractor = Int + Double public CardinalExtractor(BaseNumberOptionsConfiguration config, CJKNumberExtractorMode mode = CJKNumberExtractorMode.Default) { var builder = ImmutableDictionary.CreateBuilder <Regex, TypeTag>(); var intExtract = new IntegerExtractor(config, mode); builder.AddRange(intExtract.Regexes); var douExtractor = new DoubleExtractor(config); builder.AddRange(douExtractor.Regexes); Regexes = builder.ToImmutable(); }
// CardinalExtractor = Int + Double public CardinalExtractor(JapaneseNumberExtractorMode mode = JapaneseNumberExtractorMode.Default) { var builder = ImmutableDictionary.CreateBuilder <Regex, string>(); var intExtract = new IntegerExtractor(mode); builder.AddRange(intExtract.Regexes); var douExtractor = new DoubleExtractor(); builder.AddRange(douExtractor.Regexes); Regexes = builder.ToImmutable(); }