public void AddRuleTree(WonkaBizRulesEngine poNewRuleTree, bool pbExecuteOnChain = true) { poNewRuleTree.GroveId = GroveDesc; poNewRuleTree.GroveIndex = (uint)RuleTreeMembers.Count; RuleTreeMembers.Add(poNewRuleTree); if (pbExecuteOnChain) { ExecuteRuleTreesOnChain.Add(poNewRuleTree); } }
public void SetRuleTreeToExecuteOnChain(WonkaBizRulesEngine poTargetRuleTree, bool pbExecuteOnChain = true) { if (RuleTreeMembers.Contains(poTargetRuleTree)) { if (pbExecuteOnChain) { ExecuteRuleTreesOnChain.Add(poTargetRuleTree); } else { ExecuteRuleTreesOnChain.Remove(poTargetRuleTree); } } else { AddRuleTree(poTargetRuleTree, pbExecuteOnChain); } }