/// <summary> /// constructor for displaying a specific instance of a condition /// </summary> public ConditionDisplayHiddenDataInFile(ICondition condition, Policy.PolicyType type) : base(condition) { m_type = type; if (condition != null) { m_editable = true; } Initialise(HiddenDataInContextDescription, GetHyperlinks()); }
/// <summary> /// constructor for displaying a specific instance of a condition /// </summary> /// <param name="condition">The condition to be displayed</param> /// <param name="type">Policy type</param> public ConditionDisplayPiiInFile(ICondition condition, Policy.PolicyType type) : base(condition) { m_type = type; // condition can be null if the condition method is being displayed, without a condition instance if (condition != null) { m_editable = true; } Initialise(Properties.Resources.IDS_EXPRESSION_PIIINFILE_DESCRIPTION, GetHyperlinks()); }
/// <summary> /// constructor for displaying a specific instance of a condition /// </summary> /// <param name="condition">The condition to be displayed</param> /// <param name="type">Policy type</param> public ConditionDisplayTotalAttachmentSize(ICondition condition, Policy.PolicyType type) : base(condition) { m_type = type; if (condition != null) { m_editable = true; } base.Initialise(Properties.Resources.IDS_EXPRESSION_TOTALATTACHMENTSIZE_DESCRIPTION, GetHyperlinks()); if (condition != null) { UpdateConditionSummary(condition); } }
/// <summary> /// constructor for displaying a specific instance of a condition /// </summary> /// <param name="condition">The condition to be displayed</param> public ConditionDisplayEmbeddedEmail(ICondition condition, Policy.PolicyType type) : base(condition) { m_type = type; if (condition != null) { m_editable = true; } Initialise(Properties.Resources.IDS_EXPRESSION_EMBEDDEDEMAIL_DESCRIPTION, new RuleObject[] { }); if (condition != null) { UpdateConditionSummary(condition); } }
///<summary> //////////////////////////////////////////////////////////////////////////// /// initializeMySelf() /// Initializes fields that are reset at the beginning of the simulation, like life /// lived. ///<summary> //////////////////////////////////////////////////////////////////////////// private void ageMyself(Policy myPolicy, double deltaStep) { // Demonstration code - accessing values for computation of mortality risk... baseline // risk and relative risk. Just need to work in Policy risk modification. Can do that // later. FOR NOW - multiply baseline mortality and relative risk, test if person // dies, and move on. // At each point in time: (1) compute mortality risk and check if person dies; // (2) compute chance of switching off disease state; (3) update accumulation // of life years - taking into account whether person has been born yet; (4) // update ageNow. Note - I have included a field to accumulate life years. We // should add another one to accumulate discounted life years. // Simulate until person dies... Here's how to get the numbers needed double policyImpact = myPolicy.policyImpact; Policy.PolicyType PolicyCategory = myPolicy.policyCategory; double myRisk = MortRisk.mortRiskTable[this]; double diseaseRR = DiseaseRR.diseaseRRTable[this]; Console.WriteLine("Baseline mortality: {0}", myRisk); Console.WriteLine("Disease RR: {0}", diseaseRR); Console.ReadKey(); // TO BE DONE // TO BE DONE // TO BE DONE // TO BE DONE // TO BE DONE // TO BE DONE // TO BE DONE // TO BE DONE - Big task will be to use age, disease status, and policy to look up // probability of death. Then call on SimRandom bernouli(p) function to determine if // person dies. ALSO - have to increment life years and discounted life years (fields // not yet created). Have to do discounting. I have code for that from other simulations. }