code: public int compareTo( Object o ) {
          BoundablePair nd = (BoundablePair) o;
          if (distance < nd.distance)
              return -1;
          if (distance > nd.distance)
              return 1;
          return 0;
      }
docs: Compares two pairs based on their minimum distances