Exemple #1
0
 public static TMServer setActive_UserData_Rep(this TMServer tmServer, TMServer_UserDataRepo userDataRepo)
 {
     if (tmServer.UserDataRepos.contains(userDataRepo).isFalse())
     {
         tmServer.UserDataRepos.add(userDataRepo);
     }
     tmServer.ActiveRepo = userDataRepo.Name;
     return(tmServer);
 }
Exemple #2
0
        public static string getActive_UserData_Repo_GitPath(this TMServer tmServer)
        {
            var activeRepo = tmServer.getActive_UserData_Rep();

            if (activeRepo.notNull())
            {
                return(activeRepo.GitPath);
            }
            return(null);
        }
Exemple #3
0
 [Admin] public TM_Xml_Database ResetDatabase()
 {
     NGits = new List <API_NGit>();
     Cached_GuidanceItems        = new Dictionary <Guid, TeamMentor_Article>();
     GuidanceItems_FileMappings  = new Dictionary <Guid, string>();
     GuidanceExplorers_XmlFormat = new Dictionary <Guid, guidanceExplorer>();
     GuidanceExplorers_Paths     = new Dictionary <guidanceExplorer, string>();
     TM_Server_Config            = new TMServer();
     UserData = new TM_UserData(UsingFileStorage);
     return(this);
 }
Exemple #4
0
 public TM_Xml_Database ResetDatabase()
 {
     NGits                       = new List<API_NGit>();
     Cached_GuidanceItems        = new Dictionary<Guid, TeamMentor_Article>();
     GuidanceItems_FileMappings  = new Dictionary<Guid, string>();
     GuidanceExplorers_XmlFormat = new Dictionary<Guid, guidanceExplorer>();
     GuidanceExplorers_Paths     = new Dictionary<guidanceExplorer, string>();
     TM_Server_Config            = new TMServer();
     UserData                    = new TM_UserData(UsingFileStorage);
     return this;
 }
 [WebMethod(EnableSession = true)][Admin]                   public bool             SetTMServerFile(TMServer tmServer)
 {
     tmXmlDatabase.TM_Server_Config = tmServer;
     return(tmXmlDatabase.save_TMServer_Config());
 }
Exemple #6
0
 public bool SetTMServerFile(TMServer tmServer)
 {
     tmXmlDatabase.TM_Server_Config = tmServer;
                                                                                 return tmXmlDatabase.save_TMServer_Config();
 }
Exemple #7
0
 public static TMServer_UserDataRepo getActive_UserData_Rep(this TMServer tmServer)
 {
     return(tmServer.UserDataRepos.where (repo => repo.Name == tmServer.ActiveRepo).first());
 }