<br> Please see a previous message I sent to the list. <br> You need a constraint that asymmetrically "orders" the events, so they can match one way but not the other:<br><br>rule "Rules 1"<br> when
<br> rt: Event( name1 : name == "SimpleEvent", id1 : id )<br> ru: Event( name2: name == name1, id2 : id > id1 )<br> then<br> System.out.println("Rule matchs");
<br>end<br><br> Note the id>id1 in the above rule.<br><br> []s<br> Edson<br><br><div><span class="gmail_quote">2007/5/25, Nicolas Carlier <<a href="mailto:carlier.nicolas@gmail.com">carlier.nicolas@gmail.com
</a>>:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hy,<br><br><br>Sorry i begin with Jboss rules. But imagine that i have this rule:
<br><br>rule "Rules 1"<br> when<br> rt: Event( name1 : name, id1 : id, name == "SimpleEvent" )<br> ru: Event( name2: name, id2 : id, name == name1)<br> then<br>
<br> System.out.println("Rule matchs");<br>end<br><br>And that assert 2 objects "Event", with the same attribute name (here<br>"SimpleEvent") .<br><br>How to do that the rule wasn't executed twice ?
<br><br><br>Thanks,<br>_______________________________________________<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/rules-users">
https://lists.jboss.org/mailman/listinfo/rules-users</a><br></blockquote></div><br><br clear="all"><br>-- <br> Edson Tirelli<br> Software Engineer - JBoss Rules Core Developer<br> Office: +55 11 3529-6000<br> Mobile: +55 11 9287-5646
<br> JBoss, a division of Red Hat @ <a href="http://www.jboss.com">www.jboss.com</a>