Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## edu.stanford.nlp.sequences
Interface DocumentReaderAndWriter

All Superinterfaces:
  IteratorFromReaderFactory<List<CoreLabel>>, Serializable

All Known Implementing Classes:
  PlainTextDocumentReaderAndWriter

    public interface DocumentReaderAndWriter

extends IteratorFromReaderFactory<List<CoreLabel>>, Serializable

This interface is used for reading data and writing output into and out of `SequenceClassifier`s. If you subclass this interface, all of the other mechanisms necessary for getting your data into a `SequenceClassifier` will be taken care of for you. Subclasses MUST have an empty constructor so that they can be instantiated by reflection, and there is a promise that the init method will be called immediately after construction.

Author:
  Jenny Finkel

Method Summary
`void` | `init(SeqClassifierFlags flags)` Will be called immediately after construction.
`void` | `printAnswers(List<CoreLabel> doc, PrintWriter out)` This method prints the output of the classifier to a `PrintWriter`.

Methods inherited from interface edu.stanford.nlp.objectbank.IteratorFromReaderFactory
`getIterator`

Method Detail

### init

    void init(SeqClassifierFlags flags)

  Will be called immediately after construction. It's easier having an init() method because DocumentReaderAndWriter objects are usually created using reflection.

  Parameters:
    `flags` - Flags specifying behavior

### printAnswers

    void printAnswers(List<CoreLabel> doc,
                      PrintWriter out)

  This method prints the output of the classifier to a `PrintWriter`.

  Parameters:
    `doc` - The document which has answers (it has been classified)
    `out` - Where to send the output

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Stanford NLP Group