Exemplo n.º 1
0
  @Override
  public boolean equals(Object o) {
    if (o instanceof TermDocIdWritable) {
      TermDocIdWritable tuple = (TermDocIdWritable) o;
      return (__documentId.equals(tuple.getDocumentId()) && __term.equals(tuple.getTerm()));
    }

    return false;
  }
Exemplo n.º 2
0
  public boolean equals(Object obj) {
    boolean isEqual = false;
    if (obj instanceof TextLong) {
      TextLong other = (TextLong) obj;
      isEqual = first.equals(other.first) && second.equals(other.second);
    }

    return isEqual;
  }
Exemplo n.º 3
0
 public void run() {
   for (int i = 0; i < count; i++) {
     try {
       LongWritable param = new LongWritable(RANDOM.nextLong());
       LongWritable value = (LongWritable) client.call(param, server, null, null);
       if (!param.equals(value)) {
         LOG.fatal("Call failed!");
         failed = true;
         break;
       }
     } catch (Exception e) {
       LOG.fatal("Caught: " + StringUtils.stringifyException(e));
       failed = true;
     }
   }
 }