File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -80,6 +80,30 @@ The data dictionary supports the following types
8080Script code side
8181~~~~~~~~~~~~~~~~
8282
83+ Variable replacements
84+ ^^^^^^^^^^^^^^^^^^^^^
85+
86+ Variable replacements in the script code are done using the syntax ``{{ variable_name }} ``. For
87+ this to work, the variable ``variable_name `` has to be defined in the data dictionary passed to the
88+ ``ScriptReader ``.
89+
90+ The expression ``{{ variable_name }} `` will be replaced with the string representation of the
91+ variable's content.
92+
93+ - If the variable is a string, it has to be wrapped into quotes in the script
94+ code. e.g.
95+
96+ .. code-block :: python
97+
98+ textmsg(" {{ log_message }} " )
99+
100+
101+ - Boolean variables will be replaced with the string ``True `` or ``False ``.
102+ - Numeric variables (integer and floating point) will be replaced with the string representation generated by
103+ `std::to_string() <https://en.cppreference.com/w/cpp/string/basic_string/to_string >`_.
104+ - Version information variables will be replaced with the string representation similar to
105+ ``10.7.0.0 ``
106+
83107Boolean expressions
84108^^^^^^^^^^^^^^^^^^^
85109
You can’t perform that action at this time.
0 commit comments