Created
July 28, 2016 12:48
-
-
Save DuncanDoyle/d7e423b1d1bb30210d832d9a7c0dae89 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.signavio | |
| import org.jboss.ddoyle.bpms.test.Input; | |
| declare SimpleFact | |
| end | |
| declare AnotherFact | |
| end | |
| rule "setup rule" | |
| ruleflow-group "test-group" | |
| salience 1000 | |
| when | |
| not (SimpleFact()) | |
| not (AnotherFact()) | |
| then | |
| insert(new SimpleFact()); | |
| insert(new AnotherFact()); | |
| System.out.println("Inserting facts into memory"); | |
| end | |
| rule "rule_1" | |
| no-loop | |
| ruleflow-group "test-group" | |
| when | |
| $f : SimpleFact() | |
| $h : AnotherFact() | |
| $input : Input( ) | |
| eval(true) | |
| then | |
| System.out.println("Firing rule 1"); | |
| end | |
| rule "rule_2" | |
| no-loop | |
| ruleflow-group "test-group" | |
| when | |
| $f : SimpleFact( ) | |
| $h : AnotherFact( ) | |
| $input : Input( ) | |
| then | |
| System.out.println("Firing rule 2"); | |
| end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment