varst.utils.substitution module#
- class varst.utils.substitution.Substitution(rst_file: RstFile)#
Bases:
object
- find(name: str) str #
Find substitution text by name.
- Parameters:
name – The string value of substitution name.
- Returns:
Returns substitution text if substitution exists.
- Raises:
KeyError – If substitution is not in file.
- update(name: str, value: str) None #
Update substitution text with name to value.
- Parameters:
name – The string value of substitution name.
value – The string value of substitution text.
- varst.utils.substitution.substitution_text(name: str, value: str) str #
Create substitution text by using name and value.
- Parameters:
name – The string value of substitution name.
value – The string value of substitution text.
- Returns:
Returns substitution text.