code: public int count(Pair<T> obj) {
          long index = getIndex(obj);
          int count = counts.get(index);
          count++;
          counts.put(index, count);
          sum++;
          return count;
      }
docs: Counts the pair of objects, increasing its total count by 1.