Esempio n. 1
0
        public void Import(string path)
        {
            XmlSerializer xmlserializer = new XmlSerializer(typeof(mList <Order>));

            using (FileStream importStream = new FileStream(path, FileMode.Open))
            {
                mList <Order> temp = (mList <Order>)xmlserializer.Deserialize(importStream);
                temp.ForEach(o =>
                {
                    if (!orderList.Contains(o))
                    {
                        orderList.Add(o);
                    }
                });
            }
        }
Esempio n. 2
0
 public OrderService()
 {
     orderList = new mList <Order>();
 }