edu.northwestern.at.utils.spellcheck

## Class FileBasedSpellingDictionary

- java.lang.Object
- - edu.northwestern.at.utils.spellcheck.HashMapSpellingDictionary
  - - edu.northwestern.at.utils.spellcheck.FileBasedSpellingDictionary

- All Implemented Interfaces:
    SpellingDictionary

      public class FileBasedSpellingDictionary
      extends HashMapSpellingDictionary

  FileBasedSpellingDictionary -- implements spelling checker dictionary loaded from a file.

- - ### Field Summary

    - ### Fields inherited from class edu.northwestern.at.utils.spellcheck.HashMapSpellingDictionary

      `metaphoneDictionary`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `FileBasedSpellingDictionary(java.lang.String dictionaryFileName)` Constructs a new FileBasedSpellingDictionary.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `addWord(java.lang.String word)` Updates the dictionary.

    - ### Methods inherited from class edu.northwestern.at.utils.spellcheck.HashMapSpellingDictionary

      `addWords, clear, getAllWords, getNumberOfWords, getRelatedWords, lookupWord, read, wordCount, write`

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

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

- - ### Constructor Detail

    - #### FileBasedSpellingDictionary

          public FileBasedSpellingDictionary(java.lang.String dictionaryFileName)
                                      throws java.io.IOException

      Constructs a new FileBasedSpellingDictionary.
      Parameters:
        `dictionaryFileName` - The dictionary file name.
      Throws:
        `java.io.IOException`

  - ### Method Detail

    - #### addWord

          public boolean addWord(java.lang.String word)

      Updates the dictionary.
      Specified by:
        `addWord` in interface `SpellingDictionary`
      Overrides:
        `addWord` in class `HashMapSpellingDictionary`
      Parameters:
        `word` - The word to add to the dictionary.
      Returns:
        True if word added successfully.