All Downloads are FREE. Search and download functionalities are using the official Maven repository.

edu.stanford.nlp.trees.TreeVisitor Maven / Gradle / Ivy

Go to download

Stanford Parser processes raw text in English, Chinese, German, Arabic, and French, and extracts constituency parse trees.

There is a newer version: 3.9.2
Show newest version
package edu.stanford.nlp.trees;

/**
 * This is a simple strategy-type interface for operations that are applied to
 * Tree. It typically is called iteratively over
 * trees in a Treebank.  The convention is for TreeVisitor implementing
 * classes not to affect Tree instances they operate on, but to accomplish things via
 * side effects (like counting statistics over trees, etc.).
 *
 * @author Christopher Manning
 * @author Roger Levy
 */
public interface TreeVisitor {

  /**
   * Does whatever one needs to do to a particular parse tree.
   *
   * @param t A tree.  Classes implementing this interface can assume
   *          that the tree passed in is not null.
   */
  public void visitTree(Tree t);

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy