Hi,

I'm using accumulate with sliding windows to verify that certain event
conditions are present for a specified period of time, which works fine,
however
I need to verify that both conditions are present at the same time, i.e
Foo.value > 1 for 10 seconds and Bar.value < 1 for 10 seconds. There doesn't
appear to be an obvious way to use the temporal operators in this situation.
Can anybody offer any suggestions?

    rule test no-loop true
    when
        $f : Double(doubleValue > 1.0) from accumulate( Foo($v : value) over
window:time ( 10s )
            from entry-point EntryPoint, min($v))
        $b : Double(doubleValue < 1.0) from accumulate( Bar($v : value) over
window:time ( 10s )
            from entry-point EntryPoint, max($v))
    then
        // ...
    end

Any help greatly appreciated.

Thanks,

Paul
_______________________________________________
rules-users mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/rules-users

Reply via email to