Package com.mxgraph.layout
Class mxCompactTreeLayout.WeightedCellSorter
- java.lang.Object
-
- com.mxgraph.layout.mxCompactTreeLayout.WeightedCellSorter
-
- All Implemented Interfaces:
java.lang.Comparable<java.lang.Object>
- Enclosing class:
- mxCompactTreeLayout
protected class mxCompactTreeLayout.WeightedCellSorter extends java.lang.Object implements java.lang.Comparable<java.lang.Object>
A utility class used to track cells whilst sorting occurs on the weighted sum of their connected edges. Does not violate (x.compareTo(y)==0) == (x.equals(y))
-
-
Field Summary
Fields Modifier and Type Field Description mxCompactTreeLayout.TreeNode
cell
The cell whose median value is being calculatedboolean
nudge
Whether or not to flip equal weight values.boolean
visited
Whether or not this cell has been visited in the current assignmentint
weightedValue
The weighted value of the cell stored
-
Constructor Summary
Constructors Constructor Description WeightedCellSorter()
WeightedCellSorter(mxCompactTreeLayout.TreeNode cell, int weightedValue)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(java.lang.Object arg0)
comparator on the medianValue
-
-
-
Field Detail
-
weightedValue
public int weightedValue
The weighted value of the cell stored
-
nudge
public boolean nudge
Whether or not to flip equal weight values.
-
visited
public boolean visited
Whether or not this cell has been visited in the current assignment
-
cell
public mxCompactTreeLayout.TreeNode cell
The cell whose median value is being calculated
-
-
Constructor Detail
-
WeightedCellSorter
public WeightedCellSorter()
-
WeightedCellSorter
public WeightedCellSorter(mxCompactTreeLayout.TreeNode cell, int weightedValue)
-
-