JGraph
v5.13.0.0


com.jgraph.layout.hierarchical
Class JGraphMedianHybridCrossingReduction.MedianCellSorter

java.lang.Object
  extended by com.jgraph.layout.hierarchical.JGraphMedianHybridCrossingReduction.MedianCellSorter
All Implemented Interfaces:
Comparable
Enclosing class:
JGraphMedianHybridCrossingReduction

protected class JGraphMedianHybridCrossingReduction.MedianCellSorter
extends Object
implements Comparable

A utility class used to track cells whilst sorting occurs on the median values. Does not violate (x.compareTo(y)==0) == (x.equals(y))


Field Summary
 double medianValue
          The median value of the cell stored
 boolean nudge
          Whether or not to flip equal median values.
 
Constructor Summary
protected JGraphMedianHybridCrossingReduction.MedianCellSorter()
           
 
Method Summary
 int compareTo(Object arg0)
          comparator on the medianValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

medianValue

public double medianValue
The median value of the cell stored


nudge

public boolean nudge
Whether or not to flip equal median values.

Constructor Detail

JGraphMedianHybridCrossingReduction.MedianCellSorter

protected JGraphMedianHybridCrossingReduction.MedianCellSorter()
Method Detail

compareTo

public int compareTo(Object arg0)
comparator on the medianValue

Specified by:
compareTo in interface Comparable
Parameters:
arg0 - the object to be compared to
Returns:
the standard return you would expect when comparing two double

JGraph
v5.13.0.0


Copyright (C) 2001-2009 JGraph Ltd. All rights reserved.