sclass ExecutedRule { RuleWithParams rule; LS output; LS facts; LS newInput; Exp remainingCondition; // != null <=> rule not executed int failureLevel; // or 0 *() {} *(RuleWithParams *rule, Collection output, Collection facts, Collection newInput) { this.output = asList_nullIfEmpty(output); this.facts = asList_nullIfEmpty(facts); this.newInput = asList_nullIfEmpty(newInput); } int failureLevel() { if (failureLevel != 0) ret failureLevel; if (remainingCondition != null) failureLevel = nlLogic_failureLevel_calc(this); ret failureLevel; } }