예제 #1
0
        public static TM_Xml_Database saveVirtualArticles(this TM_Xml_Database tmXmlDatabase)
        {
            var virtualArticlesFile = tmXmlDatabase.getVirtualArticlesFile();

            var virtualArticles = tmXmlDatabase.getVirtualArticles().Values.toList();

            virtualArticles.saveAs(virtualArticlesFile);
            return(tmXmlDatabase);
        }
예제 #2
0
        public static List <VirtualArticleAction> loadVirtualArticles(this TM_Xml_Database tmXmlDatabase)
        {
            var virtualArticlesFile = tmXmlDatabase.getVirtualArticlesFile();

            if (virtualArticlesFile.fileExists())
            {
                return(virtualArticlesFile.load <List <VirtualArticleAction> >());
            }
            return(new List <VirtualArticleAction>());
        }