[rules-users] Intersecting two collections in LHS
Hezi Stern
hezis at delegatecom.com
Thu Jun 23 04:22:08 EDT 2011
I have in the working memory all possible sentences that can be presented to
the user ( class Sentence() ).
Each sentence holds a collection (String collection) called descriptor that
describe the sentence.
Based on various rules I populate a collection called messageFilter which
will be used to select the appropriate sentence.
The proper sentence is one that all its descriptors match the one in the
messageFilters
What I would like is something of the sort:
$sentences: ArrayList()
from collect (Sentence(descriptor contains messageFilter)
as messageFilter is a collection, this is not a valid code.
What would be the proper method to implement it.
I am using drools 5.1.1 but am willing to upgrade to 5.2 if required.
Thanks,
Hezi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20110623/899256b6/attachment.html
More information about the rules-users
mailing list