@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; }
@Override public int compareTo(TermDocIdWritable tuple) { int cmp = __term.compareTo(tuple.getTerm()); if (cmp != 0) { return cmp; } return __documentId.compareTo(tuple.getDocumentId()); }
public static TermDocIdWritable read(DataInput in) throws IOException { TermDocIdWritable tuple = new TermDocIdWritable(); tuple.readFields(in); return tuple; }