net.sourceforge.pmd.util.viewer.model

## Class SimpleNodeTreeNodeAdapter

- java.lang.Object
- - net.sourceforge.pmd.util.viewer.model.SimpleNodeTreeNodeAdapter

- All Implemented Interfaces:
    TreeNode

      public class SimpleNodeTreeNodeAdapter
      extends Object
      implements TreeNode

  provides the adapter for the tree model
  Version:
    $Id$
  Author:
    Boris Gruschko ( boris at gruschko.org )

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `SimpleNodeTreeNodeAdapter(SimpleNodeTreeNodeAdapter parent, Node node)` constructs the node

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `Enumeration<TreeNode>` | `children()`
    `boolean` | `getAllowsChildren()`
    `TreeNode` | `getChildAt(int childIndex)`
    `int` | `getChildCount()`
    `int` | `getIndex(TreeNode node)`
    `TreeNode` | `getParent()`
    `Node` | `getSimpleNode()` retrieves the underlying node
    `boolean` | `isLeaf()`
    `String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### SimpleNodeTreeNodeAdapter

          public SimpleNodeTreeNodeAdapter(SimpleNodeTreeNodeAdapter parent,
                                   Node node)

      constructs the node
      Parameters:
        `node` - underlying AST's node

  - ### Method Detail

    - #### getSimpleNode

          public Node getSimpleNode()

      retrieves the underlying node
      Returns:
        AST node

    - #### getChildAt

          public TreeNode getChildAt(int childIndex)

      Specified by:
        `getChildAt` in interface `TreeNode`
      See Also:
        `TreeNode.getChildAt(int)`

    - #### getChildCount

          public int getChildCount()

      Specified by:
        `getChildCount` in interface `TreeNode`
      See Also:
        `TreeNode.getChildCount()`

    - #### getParent

          public TreeNode getParent()

      Specified by:
        `getParent` in interface `TreeNode`
      See Also:
        `TreeNode.getParent()`

    - #### getIndex

          public int getIndex(TreeNode node)

      Specified by:
        `getIndex` in interface `TreeNode`
      See Also:
        `TreeNode.getIndex(javax.swing.tree.TreeNode)`

    - #### getAllowsChildren

          public boolean getAllowsChildren()

      Specified by:
        `getAllowsChildren` in interface `TreeNode`
      See Also:
        `TreeNode.getAllowsChildren()`

    - #### isLeaf

          public boolean isLeaf()

      Specified by:
        `isLeaf` in interface `TreeNode`
      See Also:
        `TreeNode.isLeaf()`

    - #### children

          public Enumeration<TreeNode> children()

      Specified by:
        `children` in interface `TreeNode`
      See Also:
        `TreeNode.children()`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`
      See Also:
        `Object.toString()`

Copyright © 2002-2013 InfoEther. All Rights Reserved.