/// <summary> /// Logins to the server by using the last used credentials.(If the user choosed to save them). /// </summary> /// <returns></returns> private bool AutoLogin() { LoginData loginData = new LoginData(LoginData.XWORD_LOGIN_DATA_FILENAME); bool canAutoLogin = loginData.CanAutoLogin(); if (canAutoLogin) { String[] credentials = loginData.GetCredentials(); serverURL = credentials[0]; username = credentials[1]; password = credentials[2]; Client = XWikiClientFactory.CreateXWikiClient(ClientType, serverURL, username, password); } return(canAutoLogin); }