Package opennlp.tools.formats.brat

# Class BratNameSampleStream

java.lang.Object
opennlp.tools.util.FilterObjectStream<S,T>
opennlp.tools.formats.brat.SegmenterObjectStream<BratDocument,NameSample>
opennlp.tools.formats.brat.BratNameSampleStream

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

public class BratNameSampleStream extends SegmenterObjectStream<BratDocument,NameSample>
Generates Name Sample objects for a Brat Document object.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `BratNameSampleStream(SentenceDetector sentDetector, Tokenizer tokenizer, ObjectStream<BratDocument> samples)`
  Creates a new `BratNameSampleStream`.
  `BratNameSampleStream(SentenceDetector sentDetector, Tokenizer tokenizer, ObjectStream<BratDocument> samples, Set<String> nameTypes)`
  Creates a new `BratNameSampleStream`.
  `BratNameSampleStream(SentenceModel sentModel, TokenizerModel tokenModel, ObjectStream<BratDocument> samples)`
  Creates a new `BratNameSampleStream`.
  `BratNameSampleStream(SentenceModel sentModel, TokenizerModel tokenModel, ObjectStream<BratDocument> samples, Set<String> nameTypes)`
  Creates a new `BratNameSampleStream`.

- ## Method Summary

  ### Methods inherited from class opennlp.tools.formats.brat.SegmenterObjectStream

  `read`

  ### Methods inherited from class opennlp.tools.util.FilterObjectStream

  `close, reset`

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

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

- ## Constructor Details

  - ### BratNameSampleStream

    public BratNameSampleStream(SentenceDetector sentDetector, Tokenizer tokenizer, ObjectStream<BratDocument> samples)
    Creates a new `BratNameSampleStream`.
    Parameters:
      `sentDetector` - a `SentenceDetector` instance
      `tokenizer` - a `Tokenizer` instance
      `samples` - a `BratDocument` `ObjectStream`

  - ### BratNameSampleStream

    public BratNameSampleStream(SentenceModel sentModel, TokenizerModel tokenModel, ObjectStream<BratDocument> samples)
    Creates a new `BratNameSampleStream`.
    Parameters:
      `sentModel` - a `SentenceModel` model
      `tokenModel` - a `TokenizerModel` model
      `samples` - a `BratDocument` `ObjectStream`

  - ### BratNameSampleStream

    public BratNameSampleStream(SentenceDetector sentDetector, Tokenizer tokenizer, ObjectStream<BratDocument> samples, Set<String> nameTypes)
    Creates a new `BratNameSampleStream`.
    Parameters:
      `sentDetector` - a `SentenceDetector` instance
      `tokenizer` - a `Tokenizer` instance
      `samples` - a `BratDocument` `ObjectStream`
      `nameTypes` - the name types to use or null if all name types

  - ### BratNameSampleStream

    public BratNameSampleStream(SentenceModel sentModel, TokenizerModel tokenModel, ObjectStream<BratDocument> samples, Set<String> nameTypes)
    Creates a new `BratNameSampleStream`.
    Parameters:
      `sentModel` - a `SentenceModel` model
      `tokenModel` - a `TokenizerModel` model
      `samples` - a `BratDocument` `ObjectStream`
      `nameTypes` - the name types to use or null if all name types