As far as I know, this should work:<br><br>package orel;<br>import orel.Main.Trigger;<br>rule ror1<br> when<br> $t : (or Trigger(fa == 1)<br> Trigger(fa == 2))<br> then<br> System.out.println( "fired " + $t.getName() );<br>
end<br><br>This is what Drools-5.0.0 kbuilder.getErrors().toString() returns:<br><br>[5,11]: [ERR 102] Line 5:11 mismatched input 'Trigger' expecting '(' in rule ror1 in pattern or[6,14]: [ERR 102] Line 6:14 mismatched input 'Trigger' expecting ')' in rule ror1[6,30]: [ERR 102] Line 6:30 mismatched input ')' expecting 'then' in rule ror1<br>
<br>Shouldn't toString() insert line ends? As it is, the result is pretty much useless.<br><br>This works:<br>rule ror1<br> when<br> (or $t : Trigger(fa == 1)<br> $t : Trigger(fa == 2))<br> then<br>
System.out.println( "fired " + $t.getName() );<br>end<br><br>-W<br><br>