From: Maxim Veksler <maxim.veksler(a)gmail.com>
Subject: [rules-users] How to write rules that can skip checking some constraint (i.e.
"or" inside the rule)
To: "Rules Users List" <rules-users(a)lists.jboss.org>
Date: Friday, January 16, 2009, 8:12 AM
Hello List,
I'm trying to express a list of channels the subscriber
is allowed to
access, this splits into 2 possible flows :
1. Subscriber has X>0 in $enabledChannels, allow passing
only for
these channels.
2. Subscriber has "null" in the $enabledChannels
- In that case
continue because this check is not required.
I'm trying to express this in the constraint node in
like this, which
does not work
$subscriber : DynaSubscriber(
adsEnabled == true,
$optoutStr : optoutStr,
enabledChannels contains $channelId // Make sure
subscriber is
"service registered" for this channel.
/*PROBLEM::::*/ or enabledChannels == null
)
I would like to be able to say, If enabledChannels is
marked (In any
way you would suggest) as "empty" don't check
this constraint node.
How can I do this?
I'm using Drools3, but if feasible solution is
presented in the form
of Drools4, 5 please kindly let me know this information.
Thank you,
Maxim.
--
Cheers,
Maxim Veksler
"Free as in Freedom" - Do u GNU ?
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users