public class WordTagSampleStream extends FilterObjectStream<java.lang.String,POSSample>
POSSample objects.| Constructor and Description |
|---|
WordTagSampleStream(ObjectStream<java.lang.String> sentences) |
WordTagSampleStream(java.io.Reader sentences)
Initializes the current instance.
|
| Modifier and Type | Method and Description |
|---|---|
POSSample |
read()
Parses the next sentence and return the next
POSSample object. |
close, resetpublic WordTagSampleStream(java.io.Reader sentences)
throws java.io.IOException
sentences - reader with sentencesjava.io.IOException - IOExceptionpublic WordTagSampleStream(ObjectStream<java.lang.String> sentences)
public POSSample read() throws java.io.IOException
POSSample object.
If an error occurs an empty POSSample object is returned
and an warning message is logged. Usually it does not matter if one
of many sentences is ignored.
TODO: An exception in error case should be thrown.java.io.IOException - if there is an error during readingCopyright © 2010 - 2020 Adobe. All Rights Reserved