[rules-users] Which rules are "passed" by object
Edson Tirelli
tirelli at post.com
Mon May 21 15:12:11 EDT 2007
Yes, you can do as suggested by Michael or you can also use the working
memory event model. Check for information in section 1.6.7 of the manual.
You can register an AgendaEventListener and hear for AfterActivationFired
events.
[]s
Edson
2007/5/21, Michael A Heese <mheese at csc.com>:
>
> Max,
>
> I'm rather new at this but I think what you can do is define a global
> variable which is a container for the information you require. For
> instance you could define a List global variable called RESULTS and for
> every rule that fired in the action you could add something to the list to
> indicate that that particular rule fired. Check section 3.3.3 of the
> documentation for informaion on global variables.
>
> Mike
>
>
>
> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery. NOTE: Regardless of content, this e-mail shall not operate to
> bind CSC to any order or other contract unless pursuant to explicit
> written
> agreement or government initiative expressly permitting the use of e-mail
> for such purpose.
>
> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>
>
>
>
> Aeternitas
> <gotischerose at yah
> oo.de> To
> Sent by: rules-users at lists.jboss.org
> rules-users-bounc cc
> es at lists.jboss.or
> g Subject
> [rules-users] Which rules are
> "passed" by object
> 05/21/2007 03:26
> AM
>
>
> Please respond to
> Rules Users List
> <rules-users at list
> s.jboss.org>
>
>
>
>
>
>
>
> Hello,
>
> I have collection of objects. I fire all rules for then and after this I
> want to know which rules were passed (or were not passed). I can't throw
> an
> Exception in rule's body, because in this case I will know only the first
> passed rule, and only for first object which passed it.
> Another solution I found - to add one more field, which will show what I
> need... But maybe there is better solution. Does Drools provide such kind
> of
> information?
>
> Thanks,
> Max
> --
> View this message in context:
>
> http://www.nabble.com/Which-rules-are-%22passed%22-by-object-tf3788713.html#a10714262
>
> 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
>
>
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
--
Edson Tirelli
Software Engineer - JBoss Rules Core Developer
Office: +55 11 3529-6000
Mobile: +55 11 9287-5646
JBoss, a division of Red Hat @ www.jboss.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20070521/171f27d2/attachment.html
More information about the rules-users
mailing list