Class WhitespaceTokenStream
java.lang.Object
opennlp.tools.util.FilterObjectStream<opennlp.tools.tokenize.TokenSample, String>
opennlp.tools.tokenize.WhitespaceTokenStream
- All Implemented Interfaces:
AutoCloseable, opennlp.tools.util.ObjectStream<String>
public class WhitespaceTokenStream
extends FilterObjectStream<opennlp.tools.tokenize.TokenSample, String>
This stream formats
ObjectStream of samples into whitespace
separated token strings.-
Constructor Summary
ConstructorsConstructorDescriptionWhitespaceTokenStream(opennlp.tools.util.ObjectStream<opennlp.tools.tokenize.TokenSample> tokens) Initializes aWhitespaceTokenStream. -
Method Summary
Methods inherited from class FilterObjectStream
close, reset
-
Constructor Details
-
WhitespaceTokenStream
public WhitespaceTokenStream(opennlp.tools.util.ObjectStream<opennlp.tools.tokenize.TokenSample> tokens) Initializes aWhitespaceTokenStream.- Parameters:
tokens- Thestreamof tokens to be separated.
-
-
Method Details
-
read
- Throws:
IOException
-