Conditions that test set membership
You can use conditions to test whether a business term belongs to a set.
A rule condition (if) states when to carry out the actions
(then and else parts) in a rule. A condition can test whether a
variable is part of a category.
- Example 1
-
This condition tests whether a customer is in the Silver, Gold, or Platinum category:
if the customer category is one of {Silver, Gold, Platinum} - Example 2
-
This condition tests whether the rule variable
luxury car groupscontains the car group that is specified in the current rental agreement. The rule first defines the variableluxury car groupsas the set of all car groups with a daily rate above a certain value:definitions set 'luxury car groups' to all car groups where the daily rate of each car group is at least 50; if 'luxury car groups' contain the car group of 'the current rental agreement'