Rule Builder > Ruleflows > Creating a Ruleflow > Creating Transition Guards

Transition guards denote the conditions under which the flow passes from one path to another. Two transitions come from the GetToday function task. To make the ruleflow valid, those two transitions must have guards, that is, Boolean conditions that will tell the engine what node must be triggered after invoking GetToday.

  1. Double-click the transition linking GetToday to GreetingDiscount. A dialog box appears in which you can edit the guard.
  2. Select the if radio button and type the line shown in Figure 9.15 in the text field:
    Note
    This text field must contain an IRL Boolean expression.

  3. images/example10.gif
  4. Figure 9.15    Transition Guard Editor Example
  5. Close the dialog box by clicking OK.
  6. In the ruleflow, the transition label now displays the value of the guard. You can change this to a more readable name by editing the label property of the transition in the Property Sheet.
  7. Click the transition and type "Is it Sunday?" in the label field of the Property Sheet.
  8. The transition label now says "Is it Sunday?".
  9. Double-click the transition linking GetToday to the end node.
  10. When the dialog box appears, select the else radio button. This sets the transition as the default path.
  11. Close the dialog box by clicking OK.

The creation of the ruleflow is now complete. Your diagram should appear similar to that in Figure 9.7.

See Also

Ruleflow Editor | Repository Element Property Reference | Working With the Property Sheet


Customer Support | Copyright © 1987-2004 ILOG S.A. All rights reserved. Legal terms. PREVIOUS   NEXT