cb.waitUntilDone();
cb.checkSuccess();
}
private LoginCredentials getLoginCredentials(String server, String user, String password, boolean isHash) {
ServerAddressFactory addressFactory = serverManager.getAddressFactory();
if (isHash) {
return new LoginCredentials(addressFactory, server, user,
new LoginCredentials.PasswordHash(password), false);
} else {
return new LoginCredentials(addressFactory, server, user, password, false, false);