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);
| 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
|
public static IDictionaryReader getOpenOfficeDictionaryReader(byte[] dicFileStream, byte[] affFileStream)
Create OpenOfficeDictionaryReader as IDictionaryReader
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)OpenOfficeDictionaryReader.public static IDictionaryReader getOpenOfficeDictionaryReader(String dicFile, String affFile)
Create OpenOfficeDictionaryReader as IDictionaryReader
dicFile - It is string full path to OpenOffice (Hunspell) dictionary file (.dic)affFile - It is string full path to OpenOffice (Hunspell) affix file (.aff)OpenOfficeDictionaryReader.Copyright © 2014. All rights reserved.