public class DependencyTreeTransformer extends java.lang.Object implements TreeTransformer
| Modifier and Type | Field and Description |
|---|---|
protected TreebankLanguagePack |
tlp |
| Constructor and Description |
|---|
DependencyTreeTransformer() |
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.String |
cleanUpLabel(java.lang.String label) |
protected static java.lang.String |
cleanUpRoot(java.lang.String label) |
protected static Tree |
stripEmptyNode(Tree t) |
protected void |
stripTag(Tree t) |
Tree |
transformTree(Tree t)
Does whatever one needs to do to a particular tree.
|
protected final TreebankLanguagePack tlp
public Tree transformTree(Tree t)
TreeTransformerTree, and could itself
work recursively, but the canonical usage is to invoke this method
via the Tree.transform() method, which will apply the
transformer in a bottom-up manner to each local Tree,
and hence the implementation of TreeTransformer should
merely examine and change a local (one-level) Tree.transformTree in interface TreeTransformert - A tree. Classes implementing this interface can assume
that the tree passed in is not null.Treeprotected static java.lang.String cleanUpRoot(java.lang.String label)
protected java.lang.String cleanUpLabel(java.lang.String label)
protected void stripTag(Tree t)