示例#1
0
        public void SaveConfig()
        {
            //Hillslope Params Data
            XmlData.SetDataToNode(HillslopeConfig.NXhs0, GetTextBoxValue(HillslopeConfig.NXhs0));
            XmlData.SetDataToNode(HillslopeConfig.NXrl0, GetTextBoxValue(HillslopeConfig.NXrl0));
            XmlData.SetDataToNode(HillslopeConfig.NThs, GetTextBoxValue(HillslopeConfig.NThs));
            XmlData.SetDataToNode(HillslopeConfig.NTrl, GetTextBoxValue(HillslopeConfig.NTrl));
            XmlData.SetDataToNode(HillslopeConfig.alfKs, GetTextBoxValue(HillslopeConfig.alfKs));
            XmlData.SetDataToNode(HillslopeConfig.alfsdp, GetTextBoxValue(HillslopeConfig.alfsdp));
            XmlData.SetDataToNode("DEPTHSLAB", GetTextBoxValue(HillslopeConfig.DEPTH_SLAB));
            XmlData.SetDataToNode(HillslopeConfig.alfroot, GetTextBoxValue(HillslopeConfig.alfroot));
            XmlData.SetDataToNode(HillslopeConfig.woleaf, GetTextBoxValue(HillslopeConfig.woleaf));
            XmlData.SetDataToNode(HillslopeConfig.czrl, GetTextBoxValue(HillslopeConfig.czrl));
            XmlData.SetDataToNode(HillslopeConfig.czov, GetTextBoxValue(HillslopeConfig.czov));
            XmlData.SetDataToNode(HillslopeConfig.bwrl0, GetTextBoxValue(HillslopeConfig.bwrl0));
            XmlData.SetDataToNode(HillslopeConfig.srinit, GetTextBoxValue(HillslopeConfig.srinit));
            XmlData.SetDataToNode(HillslopeConfig.DENSG, GetTextBoxValue(HillslopeConfig.DENSG));
            XmlData.SetDataToNode(HillslopeConfig.albedos0, GetTextBoxValue(HillslopeConfig.albedos0));
            XmlData.SetDataToNode(HillslopeConfig.albedow0, GetTextBoxValue(HillslopeConfig.albedow0));
            XmlData.SetDataToNode(HillslopeConfig.roughs0, GetTextBoxValue(HillslopeConfig.roughs0));
            XmlData.SetDataToNode(HillslopeConfig.roughw0, GetTextBoxValue(HillslopeConfig.roughw0));
            XmlData.SetDataToNode(HillslopeConfig.vlai0, GetTextBoxValue(HillslopeConfig.vlai0));
            XmlData.SetDataToNode(HillslopeConfig.CG, GetTextBoxValue(HillslopeConfig.CG));

            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Jan, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Jan));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Feb, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Feb));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Mar, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Mar));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Apr, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Apr));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.May, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.May));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Jun, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Jun));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Jul, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Jul));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Aug, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Aug));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Sep, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Sep));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Oct, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Oct));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Nov, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Nov));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_albedo + "/" + Months.Dec, GetTextBoxValue(HillslopeConfig.RMXMN_albedo + Months.Dec));

            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Jan, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Jan));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Feb, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Feb));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Mar, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Mar));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Apr, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Apr));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.May, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.May));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Jun, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Jun));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Jul, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Jul));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Aug, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Aug));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Sep, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Sep));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Oct, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Oct));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Nov, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Nov));
            XmlData.SetDataToNode(HillslopeConfig.RMXMN_z0 + "/" + Months.Dec, GetTextBoxValue(HillslopeConfig.RMXMN_z0 + Months.Dec));

            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Jan, GetTextBoxValue(HillslopeConfig.adjprec + Months.Jan));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Feb, GetTextBoxValue(HillslopeConfig.adjprec + Months.Feb));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Mar, GetTextBoxValue(HillslopeConfig.adjprec + Months.Mar));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Apr, GetTextBoxValue(HillslopeConfig.adjprec + Months.Apr));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.May, GetTextBoxValue(HillslopeConfig.adjprec + Months.May));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Jun, GetTextBoxValue(HillslopeConfig.adjprec + Months.Jun));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Jul, GetTextBoxValue(HillslopeConfig.adjprec + Months.Jul));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Aug, GetTextBoxValue(HillslopeConfig.adjprec + Months.Aug));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Sep, GetTextBoxValue(HillslopeConfig.adjprec + Months.Sep));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Oct, GetTextBoxValue(HillslopeConfig.adjprec + Months.Oct));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Nov, GetTextBoxValue(HillslopeConfig.adjprec + Months.Nov));
            XmlData.SetDataToNode(HillslopeConfig.adjprec + "/" + Months.Dec, GetTextBoxValue(HillslopeConfig.adjprec + Months.Dec));

            //Routing Parameters (Global Params + Reach Params)
            // Global Params

            XmlDataGlobals.SetDataToNode(GlobalConfig.NREACH, GetTextBoxValue(GlobalConfig.NREACH));
            XmlDataGlobals.SetDataToNode(GlobalConfig.G, GetTextBoxValue(GlobalConfig.G));
            XmlDataGlobals.SetDataToNode(GlobalConfig.TLAST, GetTextBoxValue(GlobalConfig.TLAST));
            XmlDataGlobals.SetDataToNode(GlobalConfig.OUTINT, GetTextBoxValue(GlobalConfig.OUTINT));
            XmlDataGlobals.SetDataToNode(GlobalConfig.S_OUTLET, GetTextBoxValue(GlobalConfig.S_OUTLET));
            XmlDataGlobals.SetDataToNode(GlobalConfig.TH_IC, GetTextBoxValue(GlobalConfig.TH_IC));
            XmlDataGlobals.SetDataToNode(GlobalConfig.KAPPA, GetTextBoxValue(GlobalConfig.KAPPA));
            XmlDataGlobals.SetDataToNode(GlobalConfig.LOW_D, GetTextBoxValue(GlobalConfig.LOW_D));
            XmlDataGlobals.SetDataToNode(GlobalConfig.LOW_S, GetTextBoxValue(GlobalConfig.LOW_S));
            XmlDataGlobals.SetDataToNode(GlobalConfig.L_out, GetTextBoxValue(GlobalConfig.L_out));
            XmlDataGlobals.SetDataToNode(GlobalConfig.S0MIN, GetTextBoxValue(GlobalConfig.S0MIN));
            XmlDataGlobals.SetDataToNode(GlobalConfig.S0MAX, GetTextBoxValue(GlobalConfig.S0MAX));
            XmlDataGlobals.SetDataToNode(GlobalConfig.R_INTAKE, GetTextBoxValue(GlobalConfig.R_INTAKE));
            XmlDataGlobals.SetDataToNode(GlobalConfig.Y_GW0, GetTextBoxValue(GlobalConfig.Y_GW0));
            XmlDataGlobals.SetDataToNode(GlobalConfig.LG_EXCH, GetTextBoxValue(GlobalConfig.LG_EXCH));
            XmlDataGlobals.SetDataToNode(GlobalConfig.F_SFGW, GetTextBoxValue(GlobalConfig.F_SFGW));
            XmlDataGlobals.SetDataToNode(GlobalConfig.F_CMN, GetTextBoxValue(GlobalConfig.F_CMN));
            XmlDataGlobals.SetDataToNode(GlobalConfig.F_WIDTH, GetTextBoxValue(GlobalConfig.F_WIDTH));
            XmlDataGlobals.SetDataToNode(GlobalConfig.F_YIELD, GetTextBoxValue(GlobalConfig.F_YIELD));
            XmlDataGlobals.SetDataToNode(GlobalConfig.F_TRNS, GetTextBoxValue(GlobalConfig.F_TRNS));
            XmlDataGlobals.SetDataToNode(GlobalConfig.F_LEAK, GetTextBoxValue(GlobalConfig.F_LEAK));

            //Reach Params
            SaveDataToXml();
        }
示例#2
0
        public void setRecentlyProjectPath(string path)
        {
            string node = "recent-project";

            RecentProjectDirectory.SetDataToNode(node, path);
        }