Package cross.reputation.model

Examples of cross.reputation.model.EntityIdentifier


      String userName, Collection<String> accounts) throws Exception {
    for(String accountName : accounts) {
      Community community = getCommunityByAccountName(accountName);
      if(community == null)
        continue;
      EntityIdentifier id = entity.getIdentificatorInCommunities().get(community);
      if(id == null) {
        ModelException.sendMessage(ModelException.INFO,
            "New account:"+entity.getUniqueIdentificator()+","+
            community.getName()+","+userName+","+accountName);
        entity.addIdentificatorInCommunities(community,
          new EntityIdentifier(userName, accountName));
      } else if(id.getUrl() == null) {
        ModelException.sendMessage(ModelException.INFO,"Update account:"
            +entity.getUniqueIdentificator()+","+
            community.getName()+","+userName+","+accountName);
        id.setUrl(accountName);
      }
    }
  }
View Full Code Here


          entity.getUniqueIdentificator()+" and it is discarted:"+ userArray.getString(0));
          continue;
        }
        if(!name.equals("")){
          entity.addIdentificatorInCommunities(GlobalModel.getCommunities().get(domain),
            new EntityIdentifier(user,null));
        }
        else{
          entity.addIdentificatorInCommunities(GlobalModel.getCommunities().get(domain),
            new EntityIdentifier(entity.getUniqueIdentificator(),userArray.getString(0)));
        }
         
        if(!entity.getIdentificatorInCommunities().isEmpty()) {
          GlobalModel.addEntity(entity);
        }
View Full Code Here

            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);
      }
View Full Code Here

TOP

Related Classes of cross.reputation.model.EntityIdentifier

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.