edu.northwestern.at.morphadorner.tools.tcp

## Class ExtractSoftHyphens

- java.lang.Object
- - edu.northwestern.at.morphadorner.tools.tcp.ExtractSoftHyphens

-     public class ExtractSoftHyphens
      extends java.lang.Object

  Filter hyphenated words.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected static java.util.Map<java.lang.String,java.lang.String>` | `dividedWords` Map from divided word to matching undivided word.
    `protected static java.lang.String` | `dividedWordsFileName` File containing divided words.
    `protected static java.util.Map<java.lang.String,java.lang.Number>` | `filteredDividedWords` Filtered divided words map.
    `protected static java.lang.String` | `filteredDividedWordsFileName` Fixed hyphenated words.
    `protected static java.io.PrintStream` | `printStream` Wrapper for printStream to allow utf-8 output.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ExtractSoftHyphens()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected static boolean` | `initialize(java.lang.String[] args)` Initialize.
    `static void` | `main(java.lang.String[] args)` Main program.
    `protected static java.util.Map<java.lang.String,java.lang.String>` | `processWords()` Process words.
    `protected static void` | `terminate(int wordsProcessed, long processingTime)` Terminate.

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

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

- - ### Field Detail

    - #### printStream

          protected static java.io.PrintStream printStream

      Wrapper for printStream to allow utf-8 output.

    - #### dividedWordsFileName

          protected static java.lang.String dividedWordsFileName

      File containing divided words.

    - #### filteredDividedWordsFileName

          protected static java.lang.String filteredDividedWordsFileName

      Fixed hyphenated words.

    - #### dividedWords

          protected static java.util.Map<java.lang.String,java.lang.String> dividedWords

      Map from divided word to matching undivided word.

    - #### filteredDividedWords

          protected static java.util.Map<java.lang.String,java.lang.Number> filteredDividedWords

      Filtered divided words map.

  - ### Constructor Detail

    - #### ExtractSoftHyphens

          public ExtractSoftHyphens()

  - ### Method Detail

    - #### main

          public static void main(java.lang.String[] args)

      Main program.
      Parameters:
        `args` - Program parameters.

    - #### initialize

          protected static boolean initialize(java.lang.String[] args)
                                       throws java.lang.Exception

      Initialize.
      Throws:
        `java.lang.Exception`

    - #### processWords

          protected static java.util.Map<java.lang.String,java.lang.String> processWords()

      Process words.

      Output the following for each word.

      - The divided word.
      - Probable corrected spelling.
      - Count of hyphenated word appearances.
      - Count of unhyphenated word appearances.
      - True/false if word appears unhyphenated in standard spellings list.
      - True/false if word appears hyphenated in standard spellings list.

    - #### terminate

          protected static void terminate(int wordsProcessed,
                       long processingTime)

      Terminate.
      Parameters:
        `wordsProcessed` - Number of words processed.
        `processingTime` - Processing time in seconds.