DocumentCategorizerEventStream (Apache OpenNLP Tools 2.5.9 API)
Description: declaration: package: opennlp.tools.doccat, class: DocumentCategorizerEventStream

# Class DocumentCategorizerEventStream

java.lang.Object
opennlp.tools.util.AbstractEventStream<DocumentSample>
opennlp.tools.doccat.DocumentCategorizerEventStream

All Implemented Interfaces:
  `AutoCloseable, ObjectStream<Event>`

public class DocumentCategorizerEventStream extends AbstractEventStream<DocumentSample>
Iterator-like class for modeling document classification events.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `DocumentCategorizerEventStream(ObjectStream<DocumentSample> samples)`
  Initializes a `DocumentCategorizerEventStream` via samples.
  `DocumentCategorizerEventStream(ObjectStream<DocumentSample> samples, FeatureGenerator... featureGenerators)`
  Initializes a `DocumentCategorizerEventStream` via samples and `feature generators`.

- ## Method Summary

  ### Methods inherited from class AbstractEventStream

  `close, read, reset`

  ### Methods inherited from class Object

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

- ## Constructor Details

  - ### DocumentCategorizerEventStream

    public DocumentCategorizerEventStream(ObjectStream<DocumentSample> samples, FeatureGenerator... featureGenerators)
    Initializes a `DocumentCategorizerEventStream` via samples and `feature generators`.
    Parameters:
      `samples` - `ObjectStream` of `samples`.
      `featureGenerators` - One or more `FeatureGenerator` to use.

  - ### DocumentCategorizerEventStream

    public DocumentCategorizerEventStream(ObjectStream<DocumentSample> samples)
    Initializes a `DocumentCategorizerEventStream` via samples. `BagOfWordsFeatureGenerator` is used as feature generator.
    Parameters:
      `samples` - `ObjectStream` of `samples`.