[rules-users] Testing the count of a pattern binding variable

David R Robison drrobison at openroadsconsulting.com
Mon Feb 18 16:45:03 EST 2013


I am developing rules using DSL so, from what I understand, I cannot use 
collect and accumulate in some of my DSL definitions (especially when 
using clauses that begin with a hyphen). So what I want to do is to test 
the count of a pattern binding variable, such as

when
     $sensors : Sensor()
     accumulate($sensor; $count : count(1); $count > 3)
then
     ...

Is something like this possible? I cannot seem to make it work.
David

-- 

David R Robison
Open Roads Consulting, Inc.
103 Watson Road, Chesapeake, VA 23320
phone: (757) 546-3401
e-mail: drrobison at openroadsconsulting.com
web: http://openroadsconsulting.com
blog: http://therobe.blogspot.com
book: http://www.xulonpress.com/bookstore/bookdetail.php?PB_ISBN=9781597816526



This email communication (including any attachments) may contain confidential and/or privileged material intended solely for the individual or entity to which it is addressed.
If you are not the intended recipient, please delete this email immediately.




More information about the rules-users mailing list