1234567891011121314151617181920 |
- package net.p0f.samples.rules_processes.integrity
- import net.p0f.samples.rhpam_fuse_integration.shared_dom.Award
- import net.p0f.samples.rhpam_fuse_integration.shared_dom.Customer
- rule "Incorrect Way of Matching Related Facts"
- when
- $c: Customer()
- $a: Award()
- then
- System.out.println("[WRONG] Found award " + $a.getReason() + " for customer " + $c.getName());
- end
- rule "Correct Way of Matching Related Facts"
- when
- $c: Customer()
- $a: Award(carrier == $c)
- then
- System.out.println("[RIGHT] Found award " + $a.getReason() + " for customer " + $c.getName());
- end
|