Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.encog.ml.tree.traverse.tasks
Class TaskCountNodes

    java.lang.Object
      org.encog.ml.tree.traverse.tasks.TaskCountNodes

All Implemented Interfaces:
  TreeTraversalTask

    public class TaskCountNodes

extends Object
implements TreeTraversalTask

Count the nodes in an acyclic tree.

Constructor Summary
`TaskCountNodes()` Construct the task.

Method Summary
`int` | `getNodeCount()`
`static int` | `process(TreeNode node)` Count the nodes from this tree node.
`void` | `setNodeCount(int nodeCount)` Set the current node count.
`boolean` | `task(TreeNode node)`

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

Constructor Detail

### TaskCountNodes

    public TaskCountNodes()

  Construct the task.

Method Detail

### task

    public boolean task(TreeNode node)

  Specified by:
    `task` in interface `TreeTraversalTask`
  Parameters:
    `node` - The node visiting.
  Returns:
    True, if traversal should continue.

### getNodeCount

    public int getNodeCount()

  Returns:
    The current node count.

### setNodeCount

    public void setNodeCount(int nodeCount)

  Set the current node count.

  Parameters:
    `nodeCount` - The node count.

### process

    public static int process(TreeNode node)

  Count the nodes from this tree node.

  Parameters:
    `node` - The tree node.
  Returns:
    The node count.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2014. All Rights Reserved.