java.lang.Object
net.i2p.kademlia.KBucketSet.BucketComparator<T>
- Type Parameters:
T- type of SimpleDataStructure objects being ordered
- All Implemented Interfaces:
Serializable, Comparator<KBucket<T>>
- Enclosing class:
KBucketSet<T extends SimpleDataStructure>
private static class KBucketSet.BucketComparator<T extends SimpleDataStructure>extends Object implements Comparator<KBucket<T>>, Serializable
For Collections.binarySearch. Returns equal for any overlap.
Constructor Summary
ConstructorsMethod Summary
Methods inherited from class Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Comparator
equals, max, min, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
Constructor Details
BucketComparator
private BucketComparator()Orders the buckets by their range.
Method Details
compare
- Specified by:
comparein interfaceComparator<T extends SimpleDataStructure>