contents[1] = line.substring(line.indexOf(":")+1);
//System.out.println("line:"+contents[1]);
}
try {
Double value = Double.parseDouble(contents[1]);
userPredefined.add(new Ent_Eva(new Entity(contents[0]),value));
continue;
} catch (Exception e) {}
Entity entity = new Entity(contents[0]);
contents = contents[1].split(",");
for(int i = 0; i < contents.length; i++) {
int coincidence = contents[i].indexOf("^#^");
if(coincidence == -1) {
String domain = findDomain(contents[i]);
if(domain == null) {
System.out.println("Error: domain is not known from user:"+
entity.getUniqueIdentificator()+" and it is discarted: "+contents[i]);
continue;
}
entity.addIdentificatorInCommunities(GlobalModel.getCommunities().get(domain),
new EntityIdentifier(entity.getUniqueIdentificator(),contents[i]));
} else {
String userName = contents[i].substring(0,coincidence);
//System.out.println("iu:"+entity.getUniqueIdentificator()+",u:"+userName);
String domain = findDomain(contents[i].substring(coincidence+3));
//System.out.println("d:"+domain);
if(domain == null) {
System.out.println("Error: domain is not known from user:"+
entity.getUniqueIdentificator()+"-nickname:"+userName+
" and it is discarted: "+contents[i].substring(coincidence+3));
continue;
}
entity.addIdentificatorInCommunities(GlobalModel.getCommunities().get(domain),
new EntityIdentifier(userName,null));
}
}
if(!entity.getIdentificatorInCommunities().isEmpty()) {
GlobalModel.addEntity(entity);
}
}
reader.close();
ConfigureModel.GetMoreAccounts();