Hi,
I am new to Drools, I just read documentations and went through some examples.
I am wondering about the following example (I spiced it up with a story so it should not be boring :-) ):
Suppose I am a football manager and trying to use Drools to automate some processes.
I have 11 classes (these are going to be facts):
Player1, Player2, Player3, ..., Player11
One for each player of my team, each of class has one field:
String name
In
run-time I will assert into working memory only one instance of each
class as I would like to evaluate some rules over my current team.
Now I would like to create simple rule - I express it in pseudo-language:
when
((Player1.name == "Roy") or (
Player1.name == "Bob"))
and
((Player2.name == "Tom") or (
Player2.name == "Eric"))
and
...
and
((Player11.name
== "Paulo") or (Player11.name == "Ryan"))
then
do something
Could
anyone show me how to express this rule using Drools without going into
huge number of rules? As I understand from documentation each 'or' is
creating two sub-rules. Isn't that limitation that makes Drools useless
for football managers?
regards
John
- [drools-user] Drools limitations for football managers? John Cocktolstoy
- Re: [drools-user] Drools limitations for football ... gabriel quennesson
- Re: [drools-user] Drools limitations for footb... John Cocktolstoy
- Re: [drools-user] Drools limitations for f... gabriel quennesson
- Re: [drools-user] Drools limitations f... John Cocktolstoy
- Re: [drools-user] Drools limitati... Edson Tirelli
- Re: [drools-user] Drools limi... gabriel quennesson
- Re: [drools-user] Drools ... Edson Tirelli
- Re: [drools-user] Drools ... gabriel quennesson
- Re: [drools-user] Drools ... Michael Neale
- RE: [drools-user] Drools limitations for football ... matias.zaya.mendez