Libraries tagged by order accessor
drupal-eca-recipe/eca_lib_0004
0 Favers
77 Downloads
77 Downloads
Demonstrates how to express an if/elseif/else decision in an ECA model, the pattern people usually reach for when they want a PHP switch statement. ECA has neither a switch construct nor a working exclusive gateway, so the model uses the sentinel-default idiom instead: it assigns the default value up front, lets a matching branch overwrite it, and then, one hop downstream, tests whether the value is still the default in order to detect that nothing matched. Along the way it demonstrates the four-links-to-one-target OR idiom, in which several conditioned links leaving the same predecessor point at the same successor, so that any one of them is enough to run it.