Exemple #1
0
        /// <summary>
        /// This code removes any exact duplicates from the medication list.
        /// These are unlikely to exist.
        /// </summary>
        private void RemoveExactDuplicates()
        {
            var newMedList = _medicationRule1Entries.Distinct().ToList();

            Discarded.AddRange(_medicationRule1Entries.Where(x => !newMedList.Contains(x)).Select(x => x.Element));

            _medicationRule1Entries = newMedList;
        }
Exemple #2
0
        /// <summary>
        /// In CCD 3 there is one section that has a mismatch on the name and original text.  The name is
        /// nexium and the original text is some sort of hormone replacment drug.
        /// </summary>
        private void RemoveInvalidEntries()
        {
            var newMedList = _medicationRule1Entries.Where(x => x.Name == x.OriginalText).ToList();

            Discarded.AddRange(_medicationRule1Entries.Where(x => !newMedList.Contains(x)).Select(x => x.Element));

            _medicationRule1Entries = newMedList;
        }