Example #1
0
 /// <summary>
 /// Модификация от 29 апреля 2015 года
 /// Заложен 25 февраля 2015 года
 /// </summary>
 /// <param name="pida"></param>
 /// <param name="pobty"></param>
 /// <param name="pnamo"></param>
 /// <param name="pbig"></param>
 /// <param name="plpict"></param>
 /// <param name="plbin"></param>
 /// <param name="pltex"></param>
 /// <param name="ptag"></param>
 private myleo(Guid pida, leoType pobty, string pnamo, string pbig, List <mypict> plpict, List <mybino> plbin, List <string> pltex, myTago ptag)
 {
     ida     = pida;
     obty    = pobty;
     namo    = pnamo;
     bignamo = pbig;
     if (plpict != null)
     {
         lpicto = new List <mypict>(plpict.Count);
         foreach (mypict aa in plpict)
         {
             if (aa != null)
             {
                 lpicto.Add(aa.Clone());
             }
         }
     }
     else
     {
         lpicto = null;
     }
     if (plbin != null)
     {
         lbino = new List <mybino>(plbin.Count);
         foreach (mybino aa in plbin)
         {
             if (aa != null)
             {
                 lbino.Add(aa);
             }
         }
     }
     else
     {
         lbino = null;
     }
     if (pltex != null)
     {
         ltexto = new List <string>(pltex.Count);
         foreach (string aa in pltex)
         {
             ltexto.Add(aa);
         }
     }
     else
     {
         ltexto = null;
     }
     if (ptag != null)
     {
         tago = new myTago(ptag.TStroke);
     }
     else
     {
         tago = new myTago();
     }
 }
Example #2
0
        /// <summary>
        /// Модификация от 8 января 2015 года
        /// Заложен от 8 января 2015 года
        /// </summary>
        /// <param name="typo"></param>
        /// <returns></returns>
        private leoType TypoFromString(string typo)
        {
            leoType reto = leoType.None;

            switch (typo)
            {
            case "OKPReport":
                reto = leoType.OKPReport;
                break;
            }
            return(reto);
        }
Example #3
0
        /// <summary>
        /// Модификация от 5 марта 2015 года
        /// Заложен 8 января 2015 года
        /// </summary>
        /// <param name="Elemo"></param>
        public myleo(XElement Elemo)
        {
            ida     = Guid.Parse(Elemo.Attribute("lid").Value);
            obty    = TypoFromString(Elemo.Attribute("typo").Value);
            namo    = Elemo.Element("Namo").Value;
            bignamo = Elemo.Element("BigNamo").Value;
            XElement aa = Elemo.Element("Histories");

            if (aa != null)
            {
                lhistory = new List <myhistory>();
                foreach (XElement bb in aa.Elements("History"))
                {
                    lhistory.Add(new myhistory(bb));
                }
            }
            aa = Elemo.Element("Picturyki");
            if (aa != null)
            {
                lpicto = new List <mypict>();
                foreach (XElement bb in aa.Elements("Picta"))
                {
                    lpicto.Add(new mypict(bb));
                }
            }
            aa = Elemo.Element("Binaryki");
            if (aa != null)
            {
                lbino = new List <mybino>();
                foreach (XElement bb in aa.Elements("BinaryDato"))
                {
                    lbino.Add(new mybino(bb));
                }
            }
            aa = Elemo.Element("Parameters");
            if (aa != null)
            {
                ltexto = new List <string>();
                foreach (XElement bb in aa.Elements("TParo"))
                {
                    ltexto.Add(bb.Value);
                }
            }
            aa   = Elemo.Element("Tags");
            tago = new myTago();
            if (aa != null)
            {
                foreach (XElement bb in aa.Elements("Tago"))
                {
                    tago.AddTag(bb.Value);
                }
            }
        }
Example #4
0
 /// <summary>
 /// Модификация от 2 февраля 2015 года
 ///
 /// </summary>
 /// <param name="typo"></param>
 protected myleo(leoType typo)
 {
     ida  = Guid.NewGuid();
     obty = typo;
     tago = new myTago();
 }