robot.variables.replacer
¶
VariableReplacer
¶
Source code in src/robot/variables/replacer.py
replace_list
¶
Replaces variables from a list of items.
If an item in a list is a @{list} variable its value is returned. Possible variables from other items are replaced using 'replace_scalar'. Result is always a list.
'replace_until' can be used to limit replacing arguments to certain index from the beginning. Used with Run Keyword variants that only want to resolve some arguments in the beginning and pass others to called keywords unmodified.
Source code in src/robot/variables/replacer.py
replace_scalar
¶
Replaces variables from a scalar item.
If the item is not a string it is returned as is. If it is a variable, its value is returned. Otherwise, possible variables are replaced with 'replace_string'. Result may be any object.
Source code in src/robot/variables/replacer.py
replace_string
¶
Replaces variables from a string. Result is always a string.
Input can also be an already found VariableMatch.