To determine the value of an attribute, the <attr> attributes are processed one by one in order of appearance within the parent tag. For each definition, all combinations of variables used within it are enumerated, and all non-fail values produced are collected into a set:
This behavior provides a way to determine if the variable has a specific value in its value set. The following example sets the attribute to False if the first parameter can be undefined, otherwise True:
<attr name='Completed' switch-var='%1'> <undef value='False'/> </attr> <attr name='Completed' value='True'/>