Пример #1
0
        private static SpecimenCollection Sort(SpecimenCollection specimenCollection)
        {
            SpecimenCollection            result        = new SpecimenCollection();
            IOrderedEnumerable <Specimen> orderedResult = specimenCollection.OrderBy(i => i.SpecimenName);

            foreach (Specimen specimen in orderedResult)
            {
                result.Add(specimen);
            }
            return(result);
        }
Пример #2
0
        public static SpecimenCollection GetSkins()
        {
            SpecimenCollection result = new SpecimenCollection();

            result.Add(SpecimenCollection.Instance.GetSpecimen("SKEXOSPCMN"));    // new SpecimenDefinition.SkinExcisionOrientedBiopsy());
            result.Add(SpecimenCollection.Instance.GetSpecimen("SKEXUOSPCMN"));   // new SpecimenDefinition.SkinExcisionUnorientedBiopsy());
            result.Add(SpecimenCollection.Instance.GetSpecimen("SKEXOCSPCMN"));   // new SpecimenDefinition.SkinExcisionOrientedwithCurettingsBiopsy());
            result.Add(SpecimenCollection.Instance.GetSpecimen("SKEXUOCSPCMN"));  // new SpecimenDefinition.SkinExcisionUnorientedwithCurettingsBiopsy());
            result.Add(SpecimenCollection.Instance.GetSpecimen("SKSHPHMSSPCMN")); // new SpecimenDefinition.SkinShavePunchMiscBiopsy());
            result.Add(SpecimenCollection.Instance.GetSpecimen("SKSHCSPCMN"));    // new SpecimenDefinition.SkinShavewithCurettingsBiopsy());
            return(Sort(result));
        }
Пример #3
0
        public static SpecimenCollection GetAll()
        {
            SpecimenCollection result = new SpecimenCollection();

            result.Add(new SpecimenDefinition.NullSpecimen());
            result.Add(new SpecimenDefinition.AdenoidExcision());
            result.Add(new SpecimenDefinition.AorticValve());
            result.Add(new SpecimenDefinition.AppendixExcision());
            result.Add(new SpecimenDefinition.BreastReduction());
            result.Add(new SpecimenDefinition.CervicalBiopsy());
            result.Add(new SpecimenDefinition.ECC());
            result.Add(new SpecimenDefinition.EMB());
            result.Add(new SpecimenDefinition.FemoralHead());
            result.Add(new SpecimenDefinition.FallopianTube());
            result.Add(new SpecimenDefinition.GallbladderExcision());
            result.Add(new SpecimenDefinition.GIBiopsy());
            result.Add(new SpecimenDefinition.KneeTissue());
            result.Add(new SpecimenDefinition.LEEPCone());
            result.Add(new SpecimenDefinition.LEEPPieces());
            result.Add(new SpecimenDefinition.MitralValve());
            result.Add(new SpecimenDefinition.NeedleCoreBiopsy());
            result.Add(new SpecimenDefinition.POC());
            result.Add(new SpecimenDefinition.ProstateExceptRadicalResection());
            result.Add(new SpecimenDefinition.ProstateNeedleBiopsy());
            result.Add(new SpecimenDefinition.ProstateRadicalResection());
            result.Add(new SpecimenDefinition.ProstateTUR());
            result.Add(new SpecimenDefinition.SinusContent());
            result.Add(new SpecimenDefinition.SinglePlacenta());
            result.Add(new SpecimenDefinition.SkinExcisionOrientedBiopsy());
            result.Add(new SpecimenDefinition.SkinExcisionUnorientedBiopsy());
            result.Add(new SpecimenDefinition.SkinExcisionOrientedwithCurettingsBiopsy());
            result.Add(new SpecimenDefinition.SkinExcisionUnorientedwithCurettingsBiopsy());
            result.Add(new SpecimenDefinition.SkinShavePunchMiscBiopsy());
            result.Add(new SpecimenDefinition.SkinShavewithCurettingsBiopsy());
            result.Add(new SpecimenDefinition.ThinPrepFluid());
            result.Add(new SpecimenDefinition.TonsilAdenoidExcision());
            result.Add(new SpecimenDefinition.TonsilExcision());
            result.Add(new SpecimenDefinition.Uterus());
            result.Add(new SpecimenDefinition.UterusAdnexa());
            return(Sort(result));
        }
Пример #4
0
        private static SpecimenCollection Load()
        {
            SpecimenCollection result = new SpecimenCollection();
            MySqlCommand       cmd    = new MySqlCommand("Select JSONValue from tblSpecimen;");

            cmd.CommandType = CommandType.Text;

            using (MySqlConnection cn = new MySqlConnection(YellowstonePathology.Properties.Settings.Default.CurrentConnectionString))
            {
                cn.Open();
                cmd.Connection = cn;
                using (MySqlDataReader dr = cmd.ExecuteReader())
                {
                    while (dr.Read())
                    {
                        string   jString  = dr[0].ToString();
                        Specimen specimen = FromJSON(jString);
                        result.Add(specimen);
                    }
                }
            }
            result.Add(new Specimen());
            return(Sort(result));
        }
Пример #5
0
 public static void Refresh()
 {
     instance = null;
     SpecimenCollection tmp = SpecimenCollection.Instance;
 }