Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.hyperic.image.widget
Class TreeNode

    java.lang.Object
      org.hyperic.image.widget.TreeNode

All Implemented Interfaces:
  java.io.Serializable, ITreeNode

Direct Known Subclasses:
  ResourceTreeNode

    public class TreeNode

extends java.lang.Object
implements ITreeNode, java.io.Serializable

See Also:
  Serialized Form

Field Summary
`protected java.util.Vector` | `m_downChildren`
`protected java.util.Vector` | `m_upChildren`

Constructor Summary
`TreeNode(java.lang.String name, java.lang.String desc)`
`TreeNode(java.lang.String name, java.lang.String desc, boolean selected)`

Method Summary
`void` | `addDownChild(ITreeNode child)` Adds a single child to the down children list.
`void` | `addDownChildren(ITreeNode[] children)` Add an array of children to the down children list.
`void` | `addRectangle(int x, int y, int cx, int cy)`
`void` | `addUpChild(ITreeNode child)` Adds a single child to the up children list.
`void` | `addUpChildren(ITreeNode[] children)` Add an array of children to the up children list.
`void` | `clear()` Empties the list of both up and down children.
`java.lang.String` | `getDescription()`
`ITreeNode[]` | `getDownChildren()`
`int` | `getDownChildrenCount()`
`java.awt.image.BufferedImage` | `getImage()`
`java.lang.String` | `getName()`
`java.awt.Rectangle[]` | `getRectangles()`
`ITreeNode[]` | `getUpChildren()`
`int` | `getUpChildrenCount()`
`boolean` | `hasDownChildren()`
`boolean` | `hasUpChildren()`
`boolean` | `isSelected()`
`void` | `reset()` Clears the internal state of the node.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### m_upChildren

    protected java.util.Vector m_upChildren

### m_downChildren

    protected java.util.Vector m_downChildren

Constructor Detail

### TreeNode

    public TreeNode(java.lang.String name,
                    java.lang.String desc)

### TreeNode

    public TreeNode(java.lang.String name,
                    java.lang.String desc,
                    boolean selected)

Method Detail

### addUpChild

    public void addUpChild(ITreeNode child)

  Adds a single child to the up children list.

  Parameters:
    `child` - An object that implements the IResourceTreeNode interface.
  See Also:
    `IResourceTreeNode`

### addUpChildren

    public void addUpChildren(ITreeNode[] children)

  Add an array of children to the up children list.

  Parameters:
    `children` - An array of objects that implement the IResourceTreeNode interface.
  See Also:
    `IResourceTreeNode`

### getUpChildren

    public ITreeNode[] getUpChildren()

  Specified by:
    `getUpChildren` in interface `ITreeNode`
  See Also:
    `ITreeNode.getUpChildren()`

### getUpChildrenCount

    public int getUpChildrenCount()

  Returns:
    The number of up children for this node.

### hasUpChildren

    public boolean hasUpChildren()

  Specified by:
    `hasUpChildren` in interface `ITreeNode`
  Returns:
    Whether the node has up children.

### addDownChild

    public void addDownChild(ITreeNode child)

  Adds a single child to the down children list.

  Parameters:
    `child` - An object that implements the IResourceTreeNode interface.
  See Also:
    `IResourceTreeNode`

### addDownChildren

    public void addDownChildren(ITreeNode[] children)

  Add an array of children to the down children list.

  Parameters:
    `children` - An array of objects that implement the IResourceTreeNode interface.
  See Also:
    `IResourceTreeNode`

### getDownChildren

    public ITreeNode[] getDownChildren()

  Specified by:
    `getDownChildren` in interface `ITreeNode`
  See Also:
    `ITreeNode.getDownChildren()`

### getDownChildrenCount

    public int getDownChildrenCount()

  Returns:
    The number of down children for this node.

### hasDownChildren

    public boolean hasDownChildren()

  Specified by:
    `hasDownChildren` in interface `ITreeNode`
  Returns:
    Whether the node has down children.

### clear

    public void clear()

  Empties the list of both up and down children.

### getDescription

    public java.lang.String getDescription()

  Specified by:
    `getDescription` in interface `ITreeNode`
  See Also:
    `ITreeNode.getDescription()`

### getImage

    public java.awt.image.BufferedImage getImage()

  See Also:
    `org.hyperic.util.data.ITreeNode#getImage()`

### getName

    public java.lang.String getName()

  Specified by:
    `getName` in interface `ITreeNode`
  See Also:
    `ITreeNode.getName()`

### getRectangles

    public java.awt.Rectangle[] getRectangles()

  Specified by:
    `getRectangles` in interface `ITreeNode`
  See Also:
    `ITreeNode.getRectangles()`

### isSelected

    public boolean isSelected()

  Specified by:
    `isSelected` in interface `ITreeNode`
  See Also:
    `ITreeNode.isSelected()`

### addRectangle

    public void addRectangle(int x,
                             int y,
                             int cx,
                             int cy)

  Specified by:
    `addRectangle` in interface `ITreeNode`
  See Also:
    `org.hyperic.util.data.ITreeNode#addRectangle()`

### reset

    public void reset()

  Clears the internal state of the node. The list of rectangles must be cleared at a minumum. This method is called by the ResourceTree.reset() method.

  Specified by:
    `reset` in interface `ITreeNode`
  See Also:
    `ResourceTree.reset()`

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004-2006 Hyperic, Inc. support@hyperic.net, All Rights Reserved.