-
Feature Request
-
Resolution: Done
-
Major
-
5.0.0.M2
-
None
-
None
added "Extends" keyword to DRL grammar. When a rule extends another, it will pull the entire LHS from its parent, to the current rule before execution. An example:
rule "test rule 1"
enabled false
when
c: Cheese( type == "stilton" )
then
list.add( new String ("rule 1") );
end
rule "test rule 2" extends "test rule 1"
enabled false
when
Cheese( price <= 6.00) from c
then
list.add( new String ("rule 2") );
end
rule "test rule 3" extends "test rule 2"
when
Cheese( price > 1.00 ) from c
then
list.add( new String ("rule 3") );
end
Test is in MiscTest.java