Package edu.stanford.nlp.trees
Class WordStemmer
- java.lang.Object
-
- edu.stanford.nlp.trees.WordStemmer
-
- All Implemented Interfaces:
TreeVisitor
public class WordStemmer extends Object implements TreeVisitor
Stems the Words in a Tree using Morphology.- Author:
- Huy Nguyen (htnguyen@cs.stanford.edu)
-
-
Constructor Summary
Constructors Constructor Description WordStemmer()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static voidmain(String[] args)Reads, stems, and prints the trees in the file.voidvisitTree(Tree t)Does whatever one needs to do to a particular parse tree.
-
-
-
Method Detail
-
visitTree
public void visitTree(Tree t)
Description copied from interface:TreeVisitorDoes whatever one needs to do to a particular parse tree.- Specified by:
visitTreein interfaceTreeVisitor- Parameters:
t- A tree. Classes implementing this interface can assume that the tree passed in is notnull.
-
main
public static void main(String[] args)
Reads, stems, and prints the trees in the file.- Parameters:
args- Usage: WordStemmer file
-
-