Esempio n. 1
0
        public IStrategyQueryResult NewQueryResult(string name, string[] titles, ObjectType[] types)
        {
            if (this.dic_Name_QueryResult.ContainsKey(name))
            {
                return(this.dic_Name_QueryResult[name]);
            }
            StrategyQueryResult result = new StrategyQueryResult(name, titles, types);

            this.queryResults.Add(result);
            this.dic_Name_QueryResult.Add(result.Name, result);
            return(result);
        }
Esempio n. 2
0
        public void Load(string path)
        {
            string      resultPath = GetPath(path);
            XmlDocument doc        = new XmlDocument();

            doc.Load(resultPath);
            this.Load(doc.DocumentElement);

            FileInfo f = new FileInfo(path);

            FileInfo[] queryFiles = f.Directory.GetFiles("*.queryresult");

            for (int i = 0; i < queryFiles.Length; i++)
            {
                StrategyQueryResult queryResult = new StrategyQueryResult();
                queryResult.Load(queryFiles[i].FullName);
                this.StrategyQueryResultManager.AddQueryResult(queryResult);
            }
        }