commandline.Encoder.dynamicProg
Class Tree
java.lang.Object
commandline.Encoder.dynamicProg.Tree
public class Tree
- extends java.lang.Object
Class that serves as an iterator over the nodes in the tree in a way it
traverses nodes in a bottom-up fashion and each node is visited if and only
if all its children are already visited
- Author:
- ward
|
Constructor Summary |
protected |
Tree(Node rootNode)
|
|
Method Summary |
Node |
getRootNode()
|
Node |
next()
|
void |
print()
prints the tree list in breath first order |
void |
prune(float Lagrangian,
int WHICH_NORM)
Prunes the Node tree by setting node.pruned to 'true' if they have no
children any longer |
void |
reset()
set all node.pruned=false |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
rootNode
protected Node rootNode
queue
protected java.util.PriorityQueue<Node> queue
Lagrangian
protected float Lagrangian
Tree
protected Tree(Node rootNode)
prune
public void prune(float Lagrangian,
int WHICH_NORM)
- Prunes the Node tree by setting node.pruned to 'true' if they have no
children any longer
- Parameters:
Lagrangian -
next
public Node next()
getRootNode
public Node getRootNode()
print
public void print()
- prints the tree list in breath first order
reset
public void reset()
- set all node.pruned=false