Class SentimentSampleStream
java.lang.Object
opennlp.tools.util.FilterObjectStream<String, opennlp.tools.sentiment.SentimentSample>
opennlp.tools.sentiment.SentimentSampleStream
- All Implemented Interfaces:
AutoCloseable, opennlp.tools.util.ObjectStream<opennlp.tools.sentiment.SentimentSample>
public class SentimentSampleStream
extends FilterObjectStream<String, opennlp.tools.sentiment.SentimentSample>
Class for converting Strings through Data Stream to
SentimentSample using
tokenised text.-
Constructor Summary
ConstructorsConstructorDescriptionSentimentSampleStream(opennlp.tools.util.ObjectStream<String> samples) Instantiates aSentimentSampleStreamobject. -
Method Summary
Methods inherited from class FilterObjectStream
close, reset
-
Constructor Details
-
SentimentSampleStream
Instantiates aSentimentSampleStreamobject.- Parameters:
samples- the sentiment samples to be used
-
-
Method Details
-
read
Reads the text.- Returns:
- A ready-to-be-trained
SentimentSampleobject. - Throws:
IOException
-