[rules-users] operator choices in GUVNOR for decision tables

Costello, Robert rcost10 at searshc.com
Tue Feb 3 15:36:51 EST 2009


Here's my solution for this. 

I added a model with some Lists

List stringList = Arrays.asList("Moe", "Larry", "Curly", "Edson",
"Mark");

List intList = Arrays.asList(1,2,3,4,5,6,7);

And was able to add a condition using 'contains'.  

Next step...   see if there is a way for me to add an 'or' or || column.
I'm a little less hopeful that I can get this to work. 


Robert Costello
 

-----Original Message-----
From: rules-users-bounces at lists.jboss.org
[mailto:rules-users-bounces at lists.jboss.org] On Behalf Of Costello,
Robert
Sent: Thursday, January 29, 2009 4:47 PM
To: Rules Users List
Subject: [rules-users] operator choices in GUVNOR for decision tables

Using Drools 5

I'm using a decision table in Guvnor and want to see if a value is in an
array or list, but I don't see list or collection operators available,
such as 'in', or 'contains.'  

How do I see if '5' is in [5,10,15,20] without writing a function or
otherwise writing something custom?  What am I missing?  Is there a way
to variablize an array without passing in a class? 

Thanks, 

Robert Costello

_______________________________________________
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