> would be equivalent to ::
> act :- a,b,c .
Yes, the implicit conditional operator between patterns is the conjunction
(AND).

> Event(this after $b && $b after $a)
If you read the drools manual you saw that all field expressions in drools
have a field name as the left operand (note that "this" is a special field
name). So you can't say "$b after $a". Nevertheless, even if it was possible
to do what you want, it would be awful for performance, because you would be
joining all events among themselves and only after joining, would the
constraints be applied.

Also, please note that Drools is FOL complete, so any FOL expression can be
represented. Please read about the conditional elements too, not only
restriction connectives && and ||.

[]s
Edson


2009/8/25 Khalil Hafsi <[email protected]>

>  Hi ,
>
> I am using the last version of drools fusion , what I wanted to achieve is
> to pack the rules in one "statement" , i.e :
>
>  Event(this after $b && $b after $a)
>
> instead of
>
> Event(this after $b)
> Event(this after $a)
>
> that's because I am not limited to the sequence operator , for example when
> I want to make a disjunction rule :
> Cmplx1 :- a OR b
>
> I can't separate the events , but I must write them packed like this ::
>
>  Event(this after $b || $b after this)
>
> One more question :
> I assume that the relation between the different statements in a rule is
> normal conjunction , i.e :
>
> rule "some rule"
> when
>     a : ...
>     b : ...
>     c : ...
> then
>     trigger action "act"
> end
>
> would be equivalent to ::
> act :- a,b,c .
>
> I hope I am correct ?
>
> Thanks,
> Khalil Hafsi
>
>
> _______________________________________________
> rules-users mailing list
> [email protected]
> https://lists.jboss.org/mailman/listinfo/rules-users
>
>


-- 
 Edson Tirelli
 JBoss Drools Core Development
 JBoss by Red Hat @ www.jboss.com
_______________________________________________
rules-users mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/rules-users

Reply via email to