Class MyMutableTreeMapNode

java.lang.Object
com.treemap.swing.voronoi.debug.MyMutableTreeMapNode
All Implemented Interfaces:
MutableTreeMapNode, TreeMapNode

public class MyMutableTreeMapNode extends Object implements MutableTreeMapNode
  • Constructor Summary

    Constructors
    Constructor
    Description
    MyMutableTreeMapNode(String name, int size)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    com.macrofocus.geom.Rectangle2D
    Gets the bounding rectangle of the item in the map.
    Returns the number of levels above this node -- the distance from the root to this node.
    com.macrofocus.igraphics.CPColor
     
    Returns the number of levels above this node -- the distance from the root to this node.
    int
    Returns the number of levels above this node -- the distance from the root to this node.
    com.macrofocus.geom.Shape
    Gets the shape after nesting of the item in the map.
    com.macrofocus.geom.Shape
    Gets the shape of the item in the map.
    double
    Corresponds to area in map.
    double
     
    boolean
    Tells whether this node contains children.
    boolean
     
    void
    setColor(com.macrofocus.igraphics.CPColor c)
    Sets the color of the item in the map.
    void
    setNestedShape(com.macrofocus.geom.Shape shape)
    Sets the shape after nesting of the item in the map.
    void
    setShape(com.macrofocus.geom.Shape shape)
    Sets the shape of the item in the map.
    void
    setSize(double size)
    Sets the size of the item.
    void
    setSumSize(double sumSize)
     
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • MyMutableTreeMapNode

      public MyMutableTreeMapNode(String name, int size)
  • Method Details

    • setSize

      public void setSize(double size)
      Description copied from interface: MutableTreeMapNode
      Sets the size of the item.
      Specified by:
      setSize in interface MutableTreeMapNode
      Parameters:
      size - the size of the item.
    • setSumSize

      public void setSumSize(double sumSize)
      Specified by:
      setSumSize in interface MutableTreeMapNode
    • getSumSize

      public double getSumSize()
      Specified by:
      getSumSize in interface TreeMapNode
    • setColor

      public void setColor(com.macrofocus.igraphics.CPColor c)
      Description copied from interface: MutableTreeMapNode
      Sets the color of the item in the map.
      Specified by:
      setColor in interface MutableTreeMapNode
      Parameters:
      c - the color of the item in the map.
    • getColor

      public com.macrofocus.igraphics.CPColor getColor()
      Specified by:
      getColor in interface TreeMapNode
    • setShape

      public void setShape(com.macrofocus.geom.Shape shape)
      Description copied from interface: MutableTreeMapNode
      Sets the shape of the item in the map.
      Specified by:
      setShape in interface MutableTreeMapNode
      Parameters:
      shape - the shape of the item in the map.
    • getSize

      public double getSize()
      Description copied from interface: TreeMapNode
      Corresponds to area in map.
      Specified by:
      getSize in interface TreeMapNode
      Returns:
      the area
    • getShape

      public com.macrofocus.geom.Shape getShape()
      Description copied from interface: TreeMapNode
      Gets the shape of the item in the map.
      Specified by:
      getShape in interface TreeMapNode
      Returns:
      the shape of the item in the map.
    • setNestedShape

      public void setNestedShape(com.macrofocus.geom.Shape shape)
      Description copied from interface: MutableTreeMapNode
      Sets the shape after nesting of the item in the map.
      Specified by:
      setNestedShape in interface MutableTreeMapNode
      Parameters:
      shape - the shape of the item in the map.
    • getNestedShape

      public com.macrofocus.geom.Shape getNestedShape()
      Description copied from interface: TreeMapNode
      Gets the shape after nesting of the item in the map.
      Specified by:
      getNestedShape in interface TreeMapNode
      Returns:
      the shape of the item in the map.
    • getBounds

      public com.macrofocus.geom.Rectangle2D getBounds()
      Description copied from interface: TreeMapNode
      Gets the bounding rectangle of the item in the map.
      Specified by:
      getBounds in interface TreeMapNode
      Returns:
      the bounding rectangle of the item in the map.
    • getLevel

      public int getLevel()
      Description copied from interface: TreeMapNode
      Returns the number of levels above this node -- the distance from the root to this node. If this node is the root, returns 0.
      Specified by:
      getLevel in interface TreeMapNode
      Returns:
      the number of levels above this node
    • getGroupByField

      public TreeMapField getGroupByField()
      Description copied from interface: TreeMapNode
      Returns the number of levels above this node -- the distance from the root to this node. If this node is the root, returns 0.
      Specified by:
      getGroupByField in interface TreeMapNode
      Returns:
      the number of levels above this node
    • getChildrenGroupByField

      public TreeMapField getChildrenGroupByField()
      Description copied from interface: TreeMapNode
      Returns the number of levels above this node -- the distance from the root to this node. If this node is the root, returns 0.
      Specified by:
      getChildrenGroupByField in interface TreeMapNode
      Returns:
      the number of levels above this node
    • hasNoChildren

      public boolean hasNoChildren()
      Description copied from interface: TreeMapNode
      Tells whether this node contains children.
      Specified by:
      hasNoChildren in interface TreeMapNode
      Returns:
      true if this node contains children, false otherwise
    • isLeaf

      public boolean isLeaf()
      Specified by:
      isLeaf in interface TreeMapNode
    • toString

      public String toString()
      Overrides:
      toString in class Object