transform method

String transform(
  1. String input,
  2. String output,
  3. {Map<String, dynamic>? variables,
  4. bool math = false,
  5. bool strict = false}
)

Identifies the first match of this in input and outputs a new string as defined by the output template.

If this can't be matched within the input string, the string will be output unmodified.

Implementation

String transform(
  String input,
  String output, {
  Map<String, dynamic>? variables,
  bool math = false,
  bool strict = false,
}) =>
    RegexTransformer(
      regex: this,
      output: output,
      variables: variables,
      math: math,
      strict: strict,
    ).transform(input);