/**
         * Record the milestone BinaryAnswer for the given milestone ID and then remove it from the unanswered milestones list.
         */
        public void RemoveFromVaccinationHistory(int vaccineID)
        {
            VaccineDatabaseAccess vaccineDatabaseAccess = new VaccineDatabaseAccess();

            vaccineDatabaseAccess.InitializeSync();
            Vaccine vaccine = vaccineDatabaseAccess.GetVaccineSync(vaccineID);

            VaccinationHistory.RemoveFromVaccineHistory(vaccineID);
            Boolean vaccineAddedToUnanswered = UnansweredVaccinations.AddVaccination(vaccine);

            vaccineDatabaseAccess.CloseSyncConnection();
        }
        /**
         * Record the milestone BinaryAnswer for the given milestone ID and then remove it from the unanswered milestones list.
         */
        public void AddOrUpdateVaccinationHistory(int vaccineID)
        {
            VaccineDatabaseAccess vaccineDatabaseAccess = new VaccineDatabaseAccess();

            vaccineDatabaseAccess.InitializeSync();
            Vaccine vaccine = vaccineDatabaseAccess.GetVaccineSync(vaccineID);

            VaccinationHistory.UpdateOrInsertToVaccineHistory(vaccineID);
            Boolean vaccineRemovedFromUnanswered = UnansweredVaccinations.RemoveVaccination(vaccine);

            vaccineDatabaseAccess.CloseSyncConnection();
        }
        /**
         * Retrieve a list of Vaccine objects from storage corresponding to the input list of vaccine ids.
         **/
        private List <Vaccine> GetVaccinationsByIds(List <int> ids)
        {
            VaccineDatabaseAccess vaccineDatabaseAccess = new VaccineDatabaseAccess();

            vaccineDatabaseAccess.InitializeSync();
            List <Vaccine> vaccines = new List <Vaccine>();

            if (ids != null && ids.Count > 0)
            {
                foreach (int vaccineID in ids)
                {
                    vaccines.Add(vaccineDatabaseAccess.GetVaccineSync(vaccineID));
                }
            }
            vaccineDatabaseAccess.CloseSyncConnection();
            Vaccine.SortVaccineListByDueDate(vaccines);
            return(vaccines);
        }