Ejemplo n.º 1
0
 public ImmunizationRecord(String immunizationName, int numberOfDosesGiven)
 {
     this.immunizationName     = immunizationName;
     this.numberOfDosesGiven   = numberOfDosesGiven;
     this.numberOfDosesPending = DayCareController.getImmunizationRule(this.immunizationName).getMaxNumberOfDoses() - this.numberOfDosesGiven;
     this.isOverdue            = false;
     this.isImmune             = false;
 }
Ejemplo n.º 2
0
 public void checkImmunizationStatus(DateTime bDate)
 {
     if (this.numberOfDosesPending > 0)
     {
         this.nextDueDate = DayCareController.getImmunizationRule(immunizationName).getNextDueDate(bDate, this.numberOfDosesPending);
         this.isOverdue   = nextDueDate < DateTime.Now ? true : false;
     }
     else if (this.numberOfDosesPending == 0)
     {
         this.isImmune = true;
     }
 }
Ejemplo n.º 3
0
 public static void Main(string[] args)
 {
     DayCareController.demo();
     CreateHostBuilder(args).Build().Run();
 }
Ejemplo n.º 4
0
 public void updateNumberofDosesPending()
 {
     this.numberOfDosesPending = DayCareController.getImmunizationRule(this.immunizationName).getMaxNumberOfDoses() - this.numberOfDosesGiven;
 }