Class DomGraphChartLayout.FragmentOutDegreeComparator

java.lang.Object
de.saar.chorus.domgraph.layout.chartlayout.DomGraphChartLayout.FragmentOutDegreeComparator
All Implemented Interfaces:
Comparator<String>
Enclosing class:
DomGraphChartLayout

public class DomGraphChartLayout.FragmentOutDegreeComparator extends Object implements Comparator<String>
Comparator sorting a collection of fragments ascending according to their number of outgoing edges. One-Hole fragments count as having fewer outgoing edges when if the actual number is equal.
Author:
Michaela Regneri
  • Constructor Details

    • FragmentOutDegreeComparator

      public FragmentOutDegreeComparator()
  • Method Details

    • compare

      public int compare(String arg0, String arg1)
      Specified by:
      compare in interface Comparator<String>
      Returns:
      1 if the first fragment has more outgoing edges, 0 if the number of outgoing edges is equal, -1 otherwise