[rules-users] Check if fact is subset of items in the rule

Greg Barton greg_barton at yahoo.com
Mon Oct 11 22:17:17 EDT 2010


Try the custom operator Wolfgang suggested.  Then rete will be used.

--- On Mon, 10/11/10, kpandey <kumar.pandey at gmail.com> wrote:

> From: kpandey <kumar.pandey at gmail.com>
> Subject: Re: [rules-users] Check if fact is subset of items in the rule
> To: rules-users at lists.jboss.org
> Date: Monday, October 11, 2010, 8:23 PM
> 
> I got it to work using eval like so
> 
> when
>    ...
>    eval($mycontext.isNotSubset("STRING1",
> "STRING2","STRING3", "STRING4"))
> 
> I have the logic in isNotSubset method in context class to
> check if the set
> the context is subset of array passed in the call to the
> method.
> 
> This works but I believe this can't make use of the rete
> optimization ?
> 
> 
> Thanks
> Kumar
> 
> -- 
> View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Check-if-fact-is-subset-of-items-in-the-rule-tp1680013p1684551.html
> Sent from the Drools - User mailing list archive at
> Nabble.com.
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
> 


      




More information about the rules-users mailing list