TwentyNewsgroupSampleStream (Apache OpenNLP :: Core :: Formats 3.0.0-M4 API)
Description: declaration: package: opennlp.tools.formats, class: TwentyNewsgroupSampleStream

Package opennlp.tools.formats

# Class TwentyNewsgroupSampleStream

java.lang.Object
opennlp.tools.formats.TwentyNewsgroupSampleStream

All Implemented Interfaces:
  `AutoCloseable`, `opennlp.tools.util.ObjectStream<opennlp.tools.doccat.DocumentSample>`

public class TwentyNewsgroupSampleStream extends Object implements opennlp.tools.util.ObjectStream<opennlp.tools.doccat.DocumentSample>
An `ObjectStream` implementation for the Twenty Newsgroups text corpus.

The document collection was created and donated by: Tom Mitchell, School of Computer Science, Carnegie Mellon University.

Details and the data can be found via this DOI: 10.24432/C5C323.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `opennlp.tools.doccat.DocumentSample`
  `read()`
  `void`
  `reset()`

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface opennlp.tools.util.ObjectStream

  `close`

- ## Method Details

  - ### read

    public opennlp.tools.doccat.DocumentSample read() throws IOException
    Specified by:
      `read` in interface `opennlp.tools.util.ObjectStream<opennlp.tools.doccat.DocumentSample>`
    Throws:
      `IOException`

  - ### reset

    public void reset() throws IOException, UnsupportedOperationException
    Specified by:
      `reset` in interface `opennlp.tools.util.ObjectStream<opennlp.tools.doccat.DocumentSample>`
    Throws:
      `IOException`
      `UnsupportedOperationException`