java.lang.Object
net.i2p.router.transport.udp.IntroductionManager.PeerStateComparator
- All Implemented Interfaces:
Serializable, Comparator<PeerState>
- Enclosing class:
IntroductionManager
private static class IntroductionManager.PeerStateComparatorextends Object implements Comparator<PeerState>, Serializable
For picking introducers. Lowest uptime first, to reduce idle timeout and disconnect, and ensure variety.
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateOrders peers by how recently they were introduced.Method 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
PeerStateComparator
private PeerStateComparator()Orders peers by how recently they were introduced.
Method Details
compare
- Specified by:
comparein interfaceComparator<PeerState>