I'm new to Drools and BRMS (though aware of the benefits they can provide).
I was experimenting with the Decision Table example. My goal was to create a
scenario that would return the "Combined Claims" team:

Here is the additional code I added to main(), after the others are called:

        example.teamAllocationCombined();

Below appear the additional methods that were needed:

public void teamAllocationCombined() throws Exception {
                        
        Claim cat = getCombined();
        Team team = new Team();
                
        executeRules(cat, team);
        System.out.println(team.getName());
}
        
 private Claim getCombined() {
  Claim claim = new Claim();
  claim.setCatastrophic(false);
  claim.setDateOfAccident(Calendar.getInstance().getTime());
  claim.setInsuranceClass("1");
  claim.setAllocationCode("S1");
  claim.setClaimType("T");
  claim.setInsuredVehicleOwner("Personal");
  return claim;
  
 } 

>From my reading on the Drools site, each row is a rule and will fire when
all conditions match. 

My assumption was that setting claimType to "T" would be sufficient, yet for
some reason it defaults to "Longtail". I even placed a "Stop processing" at
the end of that row that has a claimType of "T", but no joy.

What am I missing?

Thanks.



Reply via email to