Copyright © Cloud Software Group, Inc. All Rights Reserved
Copyright © Cloud Software Group, Inc. All Rights Reserved


Chapter 2 Composition of a Rule : Identifying a Rule

Identifying a Rule
Declaring a Rule Name and Its Arguments
Use the rules header to name the rule and declare any arguments. For example, in the sample rule, the rule name is EMPLOYEES_RAISE, and two arguments, JOBTITLE and REGION, are declared. The declaration ends with a semicolon (;) and arguments are enclosed in parentheses () and separated by commas (,).
Sample Rules Declaration
The following example shows the rules declaration containing the rule name and argument list:

 
RULE EDITOR ===>
EMPLOYEES_RAISE(JOBTITLE, REGION);
.....;
_ ---------------------------------------------------

 
Behavior of Rules Arguments
The scope of an argument is the rule where the argument is declared. The data representation of an argument is dynamic; it conforms to the semantic data type and syntax of the value passed to it. Argument values are passed to the rule when the rule is invoked. Passing arguments between rules is done by value; no rule can alter the value of an argument.

Copyright © Cloud Software Group, Inc. All Rights Reserved
Copyright © Cloud Software Group, Inc. All Rights Reserved