private ITerm <Value> ConstructSublimit(Dictionary <string, object> KeyValueData, bool IsItNetOfDeductible = false) { ITerm <Value> Term = (ITerm <Value>)ConstructTerm(KeyValueData); return((ITerm <Value>)Activator.CreateInstance( GetType("Sublimit<" + Term.GetType().GetGenericArguments()[0] + ">"), Term.GetExpression(), Term.GetSubject(), Term.GetTimeBasis(), IsItNetOfDeductible, Term.GetLabel())); }
private ITerm <Value> ConstructDeductible(Dictionary <string, object> KeyValueData, bool IsItAbsorbable = false) { ITerm <Value> Term = (ITerm <Value>)ConstructTerm(KeyValueData); bool IsFranchise = false; if (KeyValueData.ContainsKey("IsFranchise")) { IsFranchise = bool.Parse((string)KeyValueData["IsFranchise"]); } Interaction _Interaction = (Interaction)Enum.Parse(typeof(Interaction), (string)KeyValueData["Interaction"]); return((ITerm <Value>)Activator.CreateInstance( GetType("Deductible<" + Term.GetType().GetGenericArguments()[0] + ">"), Term.GetExpression(), Term.GetSubject(), _Interaction, IsFranchise, Term.GetTimeBasis(), Term.GetLabel(), IsItAbsorbable)); }