Ejemplo n.º 1
0
 @Override
 public int compareTo(MinigContact o) {
   if (obm.getUid() == o.obm.getUid()) {
     return 0;
   } else {
     return getLastname().compareToIgnoreCase(o.getLastname());
   }
 }
Ejemplo n.º 2
0
  public String getDisplayName() {
    StringBuilder ret = new StringBuilder();

    // last filled & maybe first
    if (!empty(getLastname())) {
      ret.append(getLastname());
      if (!empty(getFirstname())) {
        ret.append(' ');
        ret.append(getFirstname());
      }
    } else if (!empty(getFirstname())) { // last empty, first filled
      ret.append(getFirstname());
    } else { // both are empty
      logger.warn(
          "contact with both first & last empty: obm.id: "
              + obm.getUid()
              + " mails: "
              + getEmails().size());
      ret.append("[John Doe] (obm.id: " + obm.getUid() + ")");
    }

    return ret.toString();
  }
Ejemplo n.º 3
0
 public void delete(Contact c) {
   logger.info("[contact " + c.getUid() + "] scheduled for solr removal");
   Remover rm = new Remover(sContact, c.getUid().toString());
   executor.execute(rm);
 }
Ejemplo n.º 4
0
 public void createOrUpdate(Contact c) {
   logger.info("[contact " + c.getUid() + "] scheduled for solr indexing");
   ContactIndexer ci = contactIndexerFactory.createIndexer(sContact, c);
   executor.execute(ci);
 }