edu.stanford.nlp.trees.international.pennchinese
Class FragDiscardingPennTreeReader

java.lang.Object
  extended by edu.stanford.nlp.trees.PennTreeReader
      extended by edu.stanford.nlp.trees.international.pennchinese.FragDiscardingPennTreeReader
All Implemented Interfaces:
TreeReader

public class FragDiscardingPennTreeReader
extends PennTreeReader

Author:
Galen Andrew

Constructor Summary
FragDiscardingPennTreeReader(Reader in, TreeFactory tf, TreeNormalizer tn, Tokenizer tk)
           
 
Method Summary
 Tree readTree()
          Reads a single tree in standard Penn Treebank format, with or without an additional set of parens around it (an unnamed ROOT node).
 
Methods inherited from class edu.stanford.nlp.trees.PennTreeReader
close, main, tokenizerFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FragDiscardingPennTreeReader

public FragDiscardingPennTreeReader(Reader in,
                                    TreeFactory tf,
                                    TreeNormalizer tn,
                                    Tokenizer tk)
Method Detail

readTree

public Tree readTree()
              throws IOException
Description copied from class: PennTreeReader
Reads a single tree in standard Penn Treebank format, with or without an additional set of parens around it (an unnamed ROOT node). If the token stream ends before the current tree is complete, a NoSuchElementException will get thrown from deep within the innards of this method.

Specified by:
readTree in interface TreeReader
Overrides:
readTree in class PennTreeReader
Returns:
A single tree, or null at end of token stream.
Throws:
IOException


Stanford NLP Group