Vote
Bury
1

Looping in KRL

Posted in News by FatSteve 63 days ago
One of the design goals of the Kynetx Rule Language (KRL) is to make it easy to use online data sources to augment the user's experience in the browser. Using interesting data implies some kind of iteration. KRL supports both implicit and explicit looping. Ths article discusses looping in KRL and how looping in a rule language like KRL differs from how you might use it in an imperative language. First, recognize that the ruleset itself is a loop. You should imagine the rulset as a big switch statement inside a loop that is executed over and over again as the user visits pages. Persistent variables allow you to store data that can be used across separate evaluations of this loop. After each loop execution, the client is consulted for input before the loop is evaluated again. In addition to this big, implicit loop of the ruleset, there are other ways to loop in KRL. With the recent

Who Voted for this Story