edu.stanford.nlp.trees
Class PruneNodesStripSubtagsTreeNormalizer

java.lang.Object
  |
  +--edu.stanford.nlp.trees.TreeNormalizer
        |
        +--edu.stanford.nlp.trees.PruneNodesStripSubtagsTreeNormalizer

public class PruneNodesStripSubtagsTreeNormalizer
extends TreeNormalizer

??


Constructor Summary
PruneNodesStripSubtagsTreeNormalizer(Filter filter)
           
 
Method Summary
 String normalizeNonterminal(String category)
          Normalizes a nonterminal contents.
 String normalizeTerminal(String leaf)
          Normalizes a leaf contents.
 Tree normalizeWholeTree(Tree tree, TreeFactory tf)
          Normalize a whole tree -- this method assumes that the argument that it is passed is the root of a complete Tree.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PruneNodesStripSubtagsTreeNormalizer

public PruneNodesStripSubtagsTreeNormalizer(Filter filter)
Method Detail

normalizeTerminal

public String normalizeTerminal(String leaf)
Normalizes a leaf contents. This implementation interns the leaf.

Overrides:
normalizeTerminal in class TreeNormalizer

normalizeNonterminal

public String normalizeNonterminal(String category)
Normalizes a nonterminal contents. This implementation strips functional tags, etc. and interns the nonterminal.

Overrides:
normalizeNonterminal in class TreeNormalizer

normalizeWholeTree

public Tree normalizeWholeTree(Tree tree,
                               TreeFactory tf)
Description copied from class: TreeNormalizer
Normalize a whole tree -- this method assumes that the argument that it is passed is the root of a complete Tree. It is normally implemented as a Tree-walking routine.

Overrides:
normalizeWholeTree in class TreeNormalizer
Parameters:
tree - The tree to be normalized
tf - the TreeFactory to create new nodes (if needed)
Returns:
Tree the normalized tree


Stanford NLP Group