com.aspose.ocr

## Class DictionaryReaderCreator

- java.lang.Object
- - com.aspose.ocr.DictionaryReaderCreator

-     public final class DictionaryReaderCreator
      extends Object

  This class is factory of IDictionaryReader for specific dictionary format. If OcrEngine.ConfigOld.DictionaryReader is set, OcrEngine will turn on PostProcessing based on current dictionary reader.

  >      IDictionaryReader dr = DictionaryReaderCreator.getOpenOfficeDictionaryReader(
  >              stringPath + "en_GB.dic",
  >              stringPath + "en_GB.aff");
  >      OcrEngine ocr = new OcrEngine();
  >      ocr.getConfig().setDictionaryReader(dr);

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static IDictionaryReader` | `getOpenOfficeDictionaryReader(byte[] dicFileStream, byte[] affFileStream)` Create OpenOfficeDictionaryReader as IDictionaryReader
    `static IDictionaryReader` | `getOpenOfficeDictionaryReader(String dicFile, String affFile)` Create OpenOfficeDictionaryReader as IDictionaryReader

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

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

- - ### Method Detail

    - #### getOpenOfficeDictionaryReader

          public static IDictionaryReader getOpenOfficeDictionaryReader(byte[] dicFileStream,
                                                        byte[] affFileStream)

      Create OpenOfficeDictionaryReader as IDictionaryReader

      Parameters:
        `dicFileStream` - It is an array with content of OpenOffice (Hunspell) dictionary file (.dic)
        `affFileStream` - It is an array with content of OpenOffice (Hunspell) affix file (.aff)
      Returns:
        An instance of `OpenOfficeDictionaryReader`.

    - #### getOpenOfficeDictionaryReader

          public static IDictionaryReader getOpenOfficeDictionaryReader(String dicFile,
                                                        String affFile)

      Create OpenOfficeDictionaryReader as IDictionaryReader

      Parameters:
        `dicFile` - It is string full path to OpenOffice (Hunspell) dictionary file (.dic)
        `affFile` - It is string full path to OpenOffice (Hunspell) affix file (.aff)
      Returns:
        An instance of `OpenOfficeDictionaryReader`.

Copyright © 2014. All rights reserved.