edu.northwestern.at.morphadorner.tools.tcp

## Class FindSoftHyphens

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

-     public class FindSoftHyphens
      extends java.lang.Object

  Determine which words containing soft hyphens should actually be hyphenated.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected static java.util.Set<java.lang.String>` | `dividedWords` Divided words.
    `protected static java.lang.String` | `dividedWordsFileName` File containing words with a word break.
    `protected static java.lang.String` | `fixedWordsFileName` File containing fixed words.
    `protected static java.io.PrintStream` | `printStream` Wrapper for printStream to allow utf-8 output.
    `protected static java.util.Set<java.lang.String>` | `standardSpellings` Standard words.
    `protected static java.lang.String` | `standardSpellingsFileName` File containing standard spellings.
    `protected static java.util.Map<java.lang.String,java.lang.Number>` | `wordCounts` Word counts.
    `protected static java.lang.String` | `wordCountsFileName` File containing word counts.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `FindSoftHyphens()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected static int` | `getWordCount(java.lang.String word)` Get word count for a word.
    `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 words with a word break.

    - #### wordCountsFileName

          protected static java.lang.String wordCountsFileName

      File containing word counts.

    - #### standardSpellingsFileName

          protected static java.lang.String standardSpellingsFileName

      File containing standard spellings.

    - #### fixedWordsFileName

          protected static java.lang.String fixedWordsFileName

      File containing fixed words.

    - #### standardSpellings

          protected static java.util.Set<java.lang.String> standardSpellings

      Standard words.

    - #### dividedWords

          protected static java.util.Set<java.lang.String> dividedWords

      Divided words.

    - #### wordCounts

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

      Word counts.

  - ### Constructor Detail

    - #### FindSoftHyphens

          public FindSoftHyphens()

  - ### 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.

    - #### getWordCount

          protected static int getWordCount(java.lang.String word)

      Get word count for a word.
      Parameters:
        `word` - The word for which to get the count.
      Returns:
        The word count.

    - #### terminate

          protected static void terminate(int wordsProcessed,
                       long processingTime)

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