Exemple #1
0
            //---
            public Object Clone()
            {
                SYSSET cln = (SYSSET)this.MemberwiseClone();

                if (this.SEN_TBL != null)
                {
                    cln.SEN_TBL = (SENSOR_TBL[])this.SEN_TBL.Clone();
                }
                return(cln);
            }
Exemple #2
0
            public bool save(SYSSET ss)
            {
                string stCurrentDir = System.IO.Directory.GetCurrentDirectory();
                string path         = stCurrentDir + "\\SleeveInformBoard.xml";
                bool   ret          = false;

                try {
                    XmlSerializer          sz = new XmlSerializer(typeof(SYSSET));
                    System.IO.StreamWriter fs = new System.IO.StreamWriter(path, false, System.Text.Encoding.Default);
                    sz.Serialize(fs, ss);
                    fs.Close();
                    ret = true;
                }
                catch (Exception /*ex*/) {
                }
                return(ret);
            }
Exemple #3
0
            //
            public bool save(SYSSET ss)
            {
                string path = GET_SET_PATH();
                bool   ret  = false;

                try {
                    XmlSerializer          sz = new XmlSerializer(typeof(SYSSET));
                    System.IO.StreamWriter fs = new System.IO.StreamWriter(path, false, System.Text.Encoding.Default);
                    sz.Serialize(fs, ss);
                    fs.Close();
                    ret = true;
                }
                catch (Exception ex) {
                    System.Diagnostics.Debug.WriteLine(ex.ToString());
                }
                return(ret);
            }
Exemple #4
0
            public bool load(ref SYSSET ss)
            {
                string stCurrentDir = System.IO.Directory.GetCurrentDirectory();
                string path         = stCurrentDir + "\\SleeveInformBoard.xml";
                bool   ret          = false;

                try {
                    XmlSerializer          sz = new XmlSerializer(typeof(SYSSET));
                    System.IO.StreamReader fs = new System.IO.StreamReader(path, System.Text.Encoding.Default);
                    SYSSET obj;
                    obj = (SYSSET)sz.Deserialize(fs);
                    fs.Close();
                    obj = (SYSSET)obj.Clone();
                    ss  = obj;
                    ret = true;
                }
                catch (Exception /*ex*/) {
                }
                return(ret);
            }
Exemple #5
0
            //
            public bool load(ref SYSSET ss)
            {
                string path = GET_SET_PATH();
                bool   ret  = false;

                try {
                    XmlSerializer          sz = new XmlSerializer(typeof(SYSSET));
                    System.IO.StreamReader fs = new System.IO.StreamReader(path, System.Text.Encoding.Default);
                    SYSSET obj;
                    obj = (SYSSET)sz.Deserialize(fs);
                    fs.Close();
                    obj = (SYSSET)obj.Clone();
                    ss  = obj;
                    ret = true;
                }
                catch (Exception ex) {
                    System.Diagnostics.Debug.WriteLine(ex.ToString());
                }
                return(ret);
            }
Exemple #6
0
            public Object Clone()
            {
                SYSSET cln = (SYSSET)this.MemberwiseClone();

                return(cln);
            }