java.lang.Object
net.i2p.router.web.helpers.SybilRenderer.PointsComparator
All Implemented Interfaces:
Serializable, Comparator<Hash>
Enclosing class:
SybilRenderer

private static class SybilRenderer.PointsComparatorextends Object implements Comparator<Hash>, Serializable
Orders router hashes by sybil points.
  • Field Details

    • _points

      private final transient Map<Hash,Points> _points
      The points, by router hash.
  • Constructor Details

    • PointsComparator

      public PointsComparator(Map<Hash,Points> points)
      Orders hashes by sybil score, most points first.
      Parameters:
      points - the points to compare by, by router hash
  • Method Details

    • compare

      public int compare(Hash l, Hash r)
      Orders two hashes by their points, highest score first.
      Specified by:
      compare in interface Comparator<Hash>