Variable Check Rule
From TrainzOnline
(Difference between revisions)
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | The [[Variable Check Rule]] is used to execute custom rules based on the value of a [[session]] variable. For information on how to define and modify a session variable, see the [[ | + | The [[Variable Check Rule]] is used to execute custom rules based on the value of a [[session]] variable. For information on how to define and modify a session variable, see the [[Variable Modify Rule]]. The rule can be configured to test the variable value once upon execution, or once every second. Single tests are more efficient, and are recommended, but they are not always possible. If the test passes the variable check rule will then execute each of its child rules in sequence. |
+ | |||
+ | The logical comparisons supported by this rule are: | ||
+ | |||
+ | • Less than (<) | ||
+ | |||
+ | • Less than or equal to (<=) | ||
+ | |||
+ | • Equal to (==) | ||
+ | |||
+ | • Greater than (>) | ||
+ | |||
+ | • Greater than or equal to (>=) | ||
+ | |||
+ | • Not equal to (!=) | ||
+ | |||
+ | These are typical value comparison operators used by most programming languages. | ||
[[Category:Rules]] | [[Category:Rules]] |
Latest revision as of 19:40, 28 April 2013
The Variable Check Rule is used to execute custom rules based on the value of a session variable. For information on how to define and modify a session variable, see the Variable Modify Rule. The rule can be configured to test the variable value once upon execution, or once every second. Single tests are more efficient, and are recommended, but they are not always possible. If the test passes the variable check rule will then execute each of its child rules in sequence.
The logical comparisons supported by this rule are:
• Less than (<)
• Less than or equal to (<=)
• Equal to (==)
• Greater than (>)
• Greater than or equal to (>=)
• Not equal to (!=)
These are typical value comparison operators used by most programming languages.