There&#39;s a way for defining custom operators, but it&#39;s not worth the hustle<br>unless you are using this intersecion /= {} very heavily. Stay with eval.<br>-W<br><br><div class="gmail_quote">On 24 August 2010 17:42, mechlife <span dir="ltr">&lt;<a href="mailto:gaiamech@gmail.com">gaiamech@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
Hi,<br>
<br>
I have a situation where i need to evaluate a condition where the<br>
intersection of 2 sets should atleast have one element in it. I am using<br>
drools template to create the DRL and have a set B (item1,item2, item3,<br>
item4). Now, at runtime i have a setA (item2, item5). the intersection of<br>
the sets will have item2 and such should evaluate to true. I am currently<br>
using evaluate to do a custom function but just wanted to check if there was<br>
a way to do something like this by utilizing one of the existing keywords<br>
available.<br>
<br>
Any insight will be very appreciated. thanks for your time.<br>
<br>
-ms<br>
<font color="#888888">--<br>
View this message in context: <a href="http://drools-java-rules-engine.46999.n3.nabble.com/comparing-an-intersection-of-sets-tp1313555p1313555.html" target="_blank">http://drools-java-rules-engine.46999.n3.nabble.com/comparing-an-intersection-of-sets-tp1313555p1313555.html</a><br>

Sent from the Drools - User mailing list archive at Nabble.com.<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" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</font></blockquote></div><br>