Name

adams.flow.transformer.StringReplace


Synopsis

Performs a string replacement, using either String.replaceFirst(...) or String.replaceAll(...). Special characters like \n \r \t and \ need to be escaped properly. The input is expected to be escaped, i.e., the string "\t" will get turned into the character '\t'.
If the 'replace' string contains both, variables and placeholders, then first all variables are expanded and then the placeholders. This ensures that variables containing placeholders expand their placeholders as well. Not expanding placeholders will cause 'Illegal group reference' error messages.
If no regular expression matching is required, you can also use the simple replacing, which uses String.replace(...).


Additional information

Flow input/output:
- input: java.lang.String, java.lang.String[]
- output: java.lang.String, java.lang.String[]


Options