Class VoroNode
java.lang.Object
com.treemap.swing.originalfastvoronoi.VoroNode
- All Implemented Interfaces:
VoroCellObject
Represents a node in the Voronoi Treemap hierarchy. This node is put into the computation queue.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidvoidvoidint[]intintgetSite()doubledoublevoidbooleanvoiditerate()voidScales the relative vectors of the child nodes to the size of our current polygon.voidsetChildren(ArrayList<VoroNode> children) voidsetHeight(int height) voidsetNodeID(int nodeID) voidvoidsetPolygon(PolygonSimple polygon) voidsetRelativeVector(Point2D relativeVector) voidvoidsetToConsider(boolean toConsider) voidsetTreemap(VoronoiTreemap treemap) voidsetVoroPolygon(PolygonSimple polygon) voidsetWantedPercentage(double percentage) voidsetWeight(double weight)
-
Constructor Details
-
VoroNode
public VoroNode(int nodeID) -
VoroNode
public VoroNode(int nodeID, int numberChildren)
-
-
Method Details
-
calculateWeights
public void calculateWeights() -
setNodeID
public void setNodeID(int nodeID) -
getNodeID
public int getNodeID() -
setParent
-
getParent
-
setChildren
-
getChildren
-
setPolygon
-
getPolygon
-
setToConsider
public void setToConsider(boolean toConsider) -
isToConsider
public boolean isToConsider() -
setWantedPercentage
public void setWantedPercentage(double percentage) -
getWantedPercentage
public double getWantedPercentage() -
addChild
-
iterate
public void iterate() -
scaleRelativeVectors
public void scaleRelativeVectors()Scales the relative vectors of the child nodes to the size of our current polygon. Doing this helps to preserve the mental map. -
increasePercentageDirectly
public void increasePercentageDirectly() -
decreasePercentage
public void decreasePercentage() -
setHeight
public void setHeight(int height) -
getHeight
public int getHeight() -
setWeight
public void setWeight(double weight) -
getWeight
public double getWeight() -
setSite
-
getSite
-
setTreemap
-
getTreemap
-
setRelativeVector
-
getRelativeVector
-
doFinalWork
public void doFinalWork()- Specified by:
doFinalWorkin interfaceVoroCellObject
-
setVoroPolygon
- Specified by:
setVoroPolygonin interfaceVoroCellObject
-
getChildrenIDs
public int[] getChildrenIDs() -
getChildrenPolygons
-