Esempio n. 1
0
 /// <summary>
 /// 添加操作文件到当前任务.如果当前有任务正在执行,则添加到其后。
 /// </summary>
 /// <param name="gofPathes"></param>
 public void AddGofes(string[] gofPathes)
 {
     foreach (var gofPath in gofPathes)
     {
         var infos = new OperationInfoReader(gofPath).ReadAll();
         this.OperationInfos.AddRange(infos);
     }
 }
Esempio n. 2
0
        /// <summary>
        /// 从文件中解析。
        /// </summary>
        /// <param name="path"></param>
        /// <returns></returns>
        public static OperationFlow ReadFromFile(string path)
        {
            OperationFlow flow = new OperationFlow();

            flow.FileName = System.IO.Path.GetFileName(path);
            OperationInfoReader reader = new OperationInfoReader(path);

            flow.Add(reader.ReadAll());
            return(flow);
        }