org.drools.examples.cdss.GenericRules.drl Maven / Gradle / Ivy
The newest version!
package com.sample
import org.drools.examples.cdss.Terminology;
import org.drools.examples.cdss.data.Diagnose;
import org.drools.examples.cdss.data.Patient;
import org.drools.examples.cdss.data.Recommendation;
import org.drools.examples.cdss.service.RecommendationService;
global RecommendationService recommendationService
rule "Start Clinical Pathway X if diagnosed"
when
d: Diagnose( type == Terminology.DIAGNOSE_X )
then
retract(d);
drools.getWorkingMemory().startProcess(
"org.drools.examples.cdss.ClinicalPathwayX");
end
rule "Always do examination4 when patient older than 60"
when
Patient( age > 60 )
then
recommendationService.createRecommendation(
new Recommendation("Examination4"));
end
© 2015 - 2025 Weber Informatics LLC | Privacy Policy