edu.northwestern.at.morphadorner.corpuslinguistics.outputter

## Class SimpleXMLAdornedWordOutputter

- java.lang.Object
- - edu.northwestern.at.morphadorner.corpuslinguistics.outputter.PrintStreamAdornedWordOutputter
  - - edu.northwestern.at.morphadorner.corpuslinguistics.outputter.SimpleXMLAdornedWordOutputter

- All Implemented Interfaces:
    AdornedWordOutputter

      public class SimpleXMLAdornedWordOutputter
      extends PrintStreamAdornedWordOutputter
      implements AdornedWordOutputter

  Outputs adorned words to a print stream in a simple XML format.

  The output format is as follows.

  Poets Poets n2 Poets poet 0 ... ...

  There may be more or fewer word level children depending upon which output options are chosen.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected int` | `id` Word ID.

    - ### Fields inherited from class edu.northwestern.at.morphadorner.corpuslinguistics.outputter.PrintStreamAdornedWordOutputter

      `fileEncoding, fileName, printStream, separatorCharacter, wordAttributeNames`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SimpleXMLAdornedWordOutputter()` Create outputter.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()` Close outputter.
    `void` | `createOutputFile(java.lang.String fileName, java.lang.String encoding, char separatorCharacter)` Create output file.
    `void` | `outputWordAndAdornments(java.util.List<java.lang.String> wordAndAdornments)` Outputs a word and its adornments (part of speech, lemmata, etc).
    `void` | `outputWordAndAdornments(java.lang.String[] wordAndAdornments)` Outputs a word and its adornments (part of speech, lemmata, etc).

    - ### Methods inherited from class edu.northwestern.at.morphadorner.corpuslinguistics.outputter.PrintStreamAdornedWordOutputter

      `getOutputFileEncoding, getOutputFileName, setWordAttributeNames`

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

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

    - ### Methods inherited from interface edu.northwestern.at.morphadorner.corpuslinguistics.outputter.AdornedWordOutputter

      `getOutputFileEncoding, getOutputFileName, setWordAttributeNames`

- - ### Field Detail

    - #### id

          protected int id

      Word ID.

  - ### Constructor Detail

    - #### SimpleXMLAdornedWordOutputter

          public SimpleXMLAdornedWordOutputter()

      Create outputter.

  - ### Method Detail

    - #### createOutputFile

          public void createOutputFile(java.lang.String fileName,
                              java.lang.String encoding,
                              char separatorCharacter)
                                throws java.io.IOException

      Create output file.
      Specified by:
        `createOutputFile` in interface `AdornedWordOutputter`
      Overrides:
        `createOutputFile` in class `PrintStreamAdornedWordOutputter`
      Parameters:
        `fileName` - Output file name.
        `encoding` - Encoding for the output file.
        `separatorCharacter` - Output separator character.
      Throws:
        `java.io.IOException`

    - #### outputWordAndAdornments

          public void outputWordAndAdornments(java.lang.String[] wordAndAdornments)
                                       throws java.io.IOException

      Outputs a word and its adornments (part of speech, lemmata, etc).
      Specified by:
        `outputWordAndAdornments` in interface `AdornedWordOutputter`
      Overrides:
        `outputWordAndAdornments` in class `PrintStreamAdornedWordOutputter`
      Parameters:
        `wordAndAdornments` - Word and its adornments as an array of string.
      Throws:
        `java.io.IOException` - If an output error occurs.

        Outputs word and adornments as a tab-separated text line to a print stream.

    - #### outputWordAndAdornments

          public void outputWordAndAdornments(java.util.List<java.lang.String> wordAndAdornments)
                                       throws java.io.IOException

      Outputs a word and its adornments (part of speech, lemmata, etc).
      Specified by:
        `outputWordAndAdornments` in interface `AdornedWordOutputter`
      Overrides:
        `outputWordAndAdornments` in class `PrintStreamAdornedWordOutputter`
      Parameters:
        `wordAndAdornments` - Word and its adornments as a list of strings.
      Throws:
        `java.io.IOException` - If an output error occurs.

        Outputs word and adornments as a tab-separated text line to a print stream.

    - #### close

          public void close()

      Close outputter.
      Specified by:
        `close` in interface `AdornedWordOutputter`
      Overrides:
        `close` in class `PrintStreamAdornedWordOutputter`