Ejemplo n.º 1
0
        public BillingRule GetMatch(string patientType, string primaryInsurance, string secondaryInsurance, bool postDischarge, int panelSetId, bool referenceLab)
        {
            BillingRuleCollection matchedBillingRules = new BillingRuleCollection();

            foreach (BillingRule billingRule in this)
            {
                if (billingRule.IsMatch(patientType, primaryInsurance, secondaryInsurance, postDischarge, panelSetId, referenceLab) == true)
                {
                    matchedBillingRules.Add(billingRule);
                }
            }

            if (matchedBillingRules.Count == 0)
            {
                throw new Exception("There was no rule that matched.");
            }
            BillingRule matchedRule = matchedBillingRules.GetRuleWithHighestPriority();

            return(matchedRule);
        }
Ejemplo n.º 2
0
 public BillingRuleSet()
 {
     this.m_BillingRuleCollection = new BillingRuleCollection();
 }