using System; using System.Collections.Generic; using System.Text; using Thousandto.Update.Xml; using Thousandto.Update.Log; namespace Thousandto.Update.Flow { /// /// 2. 解析本地LocalVersion.xml的流程 /// public class Flow2LocalXml : BaseFlow { public override int Work() { if (!CheckLastFlowResult()) return LastFlowResult; string localXmlPath = _localXmlPath; return parseLocalVersion(localXmlPath); } public override void Uninitialize() { LocalXml = null; } //解析localversion public int parseLocalVersion(string localXmlPath) { int ret = CodeDefine.RET_SUCCESS; LocalXml = new LocalVersionXml(); ret = LocalXml.parseLocalVersionXml(localXmlPath); if (ret >= CodeDefine.RET_SUCCESS) { LocalBaseResVersion = LocalXml.BaseResVersion; } //打点解析localXml var success = ret >= CodeDefine.RET_SUCCESS; Recorder.StepRecorder.AddStep(Recorder.StepType.ParseLocalXml, success ? 0 : 1, success.ToString()); return ret; } } }