AsposeOCR
Inheritance: java.lang.Object
public class AsposeOCR
Main class for recognize text from images.
Constructors
Constructor | Description |
---|---|
AsposeOCR() | Public constructor. |
Methods
Method | Description |
---|---|
CalculateSkew(OcrInput input) | Calculates the skew angles of an images. |
CompareImageTexts(String fullPath1, String fullPath2) | Check if two images contain the same text. |
CompareImageTexts(String fullPath1, String fullPath2, RecognitionSettings settings) | Check if two images contain the same text. |
CompareImageTexts(String fullPath1, String fullPath2, RecognitionSettings settings, boolean ignoreCase) | Check if two images contain the same text. |
CorrectSpelling(String text, SpellCheck.SpellCheckLanguage language) | Corrects text (replaces misspelled words). |
CorrectSpelling(String text, SpellCheck.SpellCheckLanguage language, String dictionaryPath) | Corrects text (replaces misspelled words). |
DetectDefects(OcrInput input, DefectType defectType) | Automatically find problematic areas of an image that can significantly impact the accuracy of OCR. |
DetectRectangles(OcrInput input, AreasType areasType, boolean isDetectAreas) | Detects text areas on images. |
ImageHasText(String fullPath, String text) | Check if the image contains the provided text fragment with a case-insensitive search. |
ImageHasText(String fullPath, String text, RecognitionSettings settings) | Check if the image contains the provided text fragment with a case-insensitive search. |
ImageHasText(String fullPath, String text, RecognitionSettings settings, boolean ignoreCase) | Check if the image contains the provided text fragment. |
ImageHasText(String fullPath, Pattern regex) | Check if the image text matches the provided regular expression. |
ImageHasText(String fullPath, Pattern regex, RecognitionSettings settings) | Check if the image text matches the provided regular expression. |
ImageTextDiff(String fullPath1, String fullPath2) | Compare the texts on the two images and return a number representing how similar they are (0 to 1). |
ImageTextDiff(String fullPath1, String fullPath2, RecognitionSettings settings) | Compare the texts on the two images and return a number representing how similar they are (0 to 1). |
ImageTextDiff(String fullPath1, String fullPath2, RecognitionSettings settings, boolean ignoreCase) | Compare the texts on the two images and return a number representing how similar they are (0 to 1). |
Recognize(OcrInput input) | Recognizes image with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64. |
Recognize(OcrInput input, RecognitionSettings settings) | Recognizes image with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64. |
RecognizeCarPlate(OcrInput input, CarPlateRecognitionSettings settings) | Recognizes car plate with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64. |
RecognizeCharacters(OcrInput input) | Detects symbols on images. |
RecognizeCharacters(OcrInput input, DetectAreasMode detectAreasMode, Language language) | Detects symbols on images. |
RecognizeFast(OcrInput input) | Recognizes text on good quality image. |
RecognizeHandwrittenText(OcrInput input) | Recognizes handwritten text on images. |
RecognizeIDCard(OcrInput input, IDCardRecognitionSettings settings) | Recognizes ID card with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64. |
RecognizeInvoice(OcrInput input, InvoiceRecognitionSettings settings) | Recognizes invoice with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64. |
RecognizePassport(OcrInput input, PassportRecognitionSettings settings) | Recognizes passport with the ability to specify. |
RecognizeReceipt(OcrInput input, ReceiptRecognitionSettings settings) | Recognizes receipts with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64. |
RecognizeStreetPhoto(OcrInput input) | Recognizes text on street photos. |
SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList | Allows to get multipage document from list of RecognitionResult objects. |
SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList | Allows to get multipage document from list of RecognitionResult objects. |
SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList | Allows to get multipage document from list of RecognitionResult objects. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList | Allows to get multipage document from list of RecognitionResult objects. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList | Allows to get multipage document from list of RecognitionResult objects with spell-check correction. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList | Allows to get multipage document from list of RecognitionResult objects. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList | Allows to get multipage document from list of RecognitionResult objects. |
AsposeOCR()
public AsposeOCR()
Public constructor.
CalculateSkew(OcrInput input)
public ArrayList<SkewOutput> CalculateSkew(OcrInput input)
Calculates the skew angles of an images. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | The container with sources.OcrInput |
Returns: java.util.ArrayList<com.aspose.ocr.SkewOutput> - ArrayList of skew angles in degrees SkewOutput
CompareImageTexts(String fullPath1, String fullPath2)
public boolean CompareImageTexts(String fullPath1, String fullPath2)
Check if two images contain the same text.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath1 | java.lang.String | Path to the first image. |
fullPath2 | java.lang.String | Path to the second image. |
Returns: boolean - True if images have the same text (90% similarity).
CompareImageTexts(String fullPath1, String fullPath2, RecognitionSettings settings)
public boolean CompareImageTexts(String fullPath1, String fullPath2, RecognitionSettings settings)
Check if two images contain the same text.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath1 | java.lang.String | Path to the first image. |
fullPath2 | java.lang.String | Path to the second image. |
settings | RecognitionSettings | Recognition settings. |
Returns: boolean - True if images have the same text (90% similarity).
CompareImageTexts(String fullPath1, String fullPath2, RecognitionSettings settings, boolean ignoreCase)
public boolean CompareImageTexts(String fullPath1, String fullPath2, RecognitionSettings settings, boolean ignoreCase)
Check if two images contain the same text.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath1 | java.lang.String | Path to the first image. |
fullPath2 | java.lang.String | Path to the second image. |
settings | RecognitionSettings | Recognition settings. |
ignoreCase | boolean | True - means a case-insensitive search. |
Returns: boolean - True if images have the same text (90% similarity).
CorrectSpelling(String text, SpellCheck.SpellCheckLanguage language)
public String CorrectSpelling(String text, SpellCheck.SpellCheckLanguage language)
Corrects text (replaces misspelled words).
Parameters:
Parameter | Type | Description |
---|---|---|
text | java.lang.String | Text for correction. |
language | SpellCheckLanguage | Dictionary to use SpellCheckLanguage. |
Returns: java.lang.String - Text with replaced words.
CorrectSpelling(String text, SpellCheck.SpellCheckLanguage language, String dictionaryPath)
public String CorrectSpelling(String text, SpellCheck.SpellCheckLanguage language, String dictionaryPath)
Corrects text (replaces misspelled words).
Parameters:
Parameter | Type | Description |
---|---|---|
text | java.lang.String | Text for correction. |
language | SpellCheckLanguage | Dictionary to use SpellCheckLanguage. |
dictionaryPath | java.lang.String | Full path to the user dictionary (frequency dictionary). Dictionary file format: Plain text file in UTF-8 encoding. Word and Word Frequency are separated by comma, the word is expected in the first column and the frequency in the second column. Every word-frequency-pair in a separate line.A line is defined as a sequence of characters followed by a line feed ("\n"), a carriage return ("\r"), or a carriage return immediately followed by a line feed("\r\n"). Every word is expected to be in lower case. |
Returns: java.lang.String - Text with replaced words.
DetectDefects(OcrInput input, DefectType defectType)
public ArrayList<DefectOutput> DetectDefects(OcrInput input, DefectType defectType)
Automatically find problematic areas of an image that can significantly impact the accuracy of OCR. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | The container with sources.OcrInput |
defectType | DefectType | The types of defects to be recognized DefectType. |
Returns: java.util.ArrayList<com.aspose.ocr.DefectOutput> - ArrayList of DefectOutput with detected text areas or lines.
DetectRectangles(OcrInput input, AreasType areasType, boolean isDetectAreas)
public ArrayList<RectangleOutput> DetectRectangles(OcrInput input, AreasType areasType, boolean isDetectAreas)
Detects text areas on images. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | The container with sources.OcrInput |
areasType | AreasType | Determinates wich rectangles to return - line or paragraphs. |
isDetectAreas | boolean | Enable automatic text areas detection. |
Returns: java.util.ArrayList<com.aspose.ocr.RectangleOutput> - ArrayList of RectangleOutput with detected text areas or lines.
ImageHasText(String fullPath, String text)
public boolean ImageHasText(String fullPath, String text)
Check if the image contains the provided text fragment with a case-insensitive search.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath | java.lang.String | Path to the image. |
text | java.lang.String | Text fragment for searching on the image. |
Returns: boolean - True if image contains text fragment. False - image doesn’t contains text fragment.
ImageHasText(String fullPath, String text, RecognitionSettings settings)
public boolean ImageHasText(String fullPath, String text, RecognitionSettings settings)
Check if the image contains the provided text fragment with a case-insensitive search.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath | java.lang.String | Path to the image. |
text | java.lang.String | Text fragment for searching on the image. |
settings | RecognitionSettings | Recognition settings. |
Returns: boolean - True if image contains text fragment. False - image doesn’t contains text fragment.
ImageHasText(String fullPath, String text, RecognitionSettings settings, boolean ignoreCase)
public boolean ImageHasText(String fullPath, String text, RecognitionSettings settings, boolean ignoreCase)
Check if the image contains the provided text fragment.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath | java.lang.String | Path to the image. |
text | java.lang.String | Text fragment for searching on the image. |
settings | RecognitionSettings | Recognition settings. |
ignoreCase | boolean | True - means a case-insensitive search. |
Returns: boolean - True if image contains text fragment. False - image doesn’t contains text fragment.
ImageHasText(String fullPath, Pattern regex)
public boolean ImageHasText(String fullPath, Pattern regex)
Check if the image text matches the provided regular expression.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath | java.lang.String | Path to the image. |
regex | java.util.regex.Pattern | java.util.regex.Pattern object with the provided pattern and options. |
Returns: boolean - True if image text matches the provided regular expression.
ImageHasText(String fullPath, Pattern regex, RecognitionSettings settings)
public boolean ImageHasText(String fullPath, Pattern regex, RecognitionSettings settings)
Check if the image text matches the provided regular expression.
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath | java.lang.String | Path to the image. |
regex | java.util.regex.Pattern | java.util.regex.Pattern object with the provided pattern and options. |
settings | RecognitionSettings | Recognition settings. |
Returns: boolean - True if image text matches the provided regular expression.
ImageTextDiff(String fullPath1, String fullPath2)
public float ImageTextDiff(String fullPath1, String fullPath2)
Compare the texts on the two images and return a number representing how similar they are (0 to 1).
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath1 | java.lang.String | Path to the first image. |
fullPath2 | java.lang.String | Path to the second image. |
Returns: float - 0 means that the texts are completely different; 1 means the texts are identical.
ImageTextDiff(String fullPath1, String fullPath2, RecognitionSettings settings)
public float ImageTextDiff(String fullPath1, String fullPath2, RecognitionSettings settings)
Compare the texts on the two images and return a number representing how similar they are (0 to 1).
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath1 | java.lang.String | Path to the first image. |
fullPath2 | java.lang.String | Path to the second image. |
settings | RecognitionSettings | Recognition settings. |
Returns: float - 0 means that the texts are completely different; 1 means the texts are identical.
ImageTextDiff(String fullPath1, String fullPath2, RecognitionSettings settings, boolean ignoreCase)
public float ImageTextDiff(String fullPath1, String fullPath2, RecognitionSettings settings, boolean ignoreCase)
Compare the texts on the two images and return a number representing how similar they are (0 to 1).
Parameters:
Parameter | Type | Description |
---|---|---|
fullPath1 | java.lang.String | Path to the first image. |
fullPath2 | java.lang.String | Path to the second image. |
settings | RecognitionSettings | Recognition settings. |
ignoreCase | boolean | True - means a case-insensitive search. |
Returns: float - 0 means that the texts are completely different; 1 means the texts are identical.
Recognize(OcrInput input)
public ArrayList<RecognitionResult> Recognize(OcrInput input)
Recognizes image with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. instance. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
Recognize(OcrInput input, RecognitionSettings settings)
public ArrayList<RecognitionResult> Recognize(OcrInput input, RecognitionSettings settings)
Recognizes image with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. instance. |
settings | RecognitionSettings | RecognitionSettings. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
RecognizeCarPlate(OcrInput input, CarPlateRecognitionSettings settings)
public ArrayList<RecognitionResult> RecognizeCarPlate(OcrInput input, CarPlateRecognitionSettings settings)
Recognizes car plate with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. instance. |
settings | CarPlateRecognitionSettings | CarPlateRecognitionSettings. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
RecognizeCharacters(OcrInput input)
public ArrayList<CharacterRecognitionResult> RecognizeCharacters(OcrInput input)
Detects symbols on images. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | The container with sources.OcrInput |
Returns: java.util.ArrayList<com.aspose.ocr.CharacterRecognitionResult> - ArrayList of Character with detected symbols data for each image.
RecognizeCharacters(OcrInput input, DetectAreasMode detectAreasMode, Language language)
public ArrayList<CharacterRecognitionResult> RecognizeCharacters(OcrInput input, DetectAreasMode detectAreasMode, Language language)
Detects symbols on images. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | The container with sources.OcrInput |
detectAreasMode | DetectAreasMode | Determines the type of neural network used for areas detection. |
language | Language | Language used for OCR. |
Returns: java.util.ArrayList<com.aspose.ocr.CharacterRecognitionResult> - ArrayList of Character with detected symbols data.
RecognizeFast(OcrInput input)
public ArrayList<String> RecognizeFast(OcrInput input)
Recognizes text on good quality image. Doesn’t use automatic image skew correction and text areas detection. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput instance. |
Returns: java.util.ArrayList<java.lang.String> - ArrayList with recognized text.
RecognizeHandwrittenText(OcrInput input)
public ArrayList<RecognitionResult> RecognizeHandwrittenText(OcrInput input)
Recognizes handwritten text on images. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. The container with sources.. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
RecognizeIDCard(OcrInput input, IDCardRecognitionSettings settings)
public ArrayList<RecognitionResult> RecognizeIDCard(OcrInput input, IDCardRecognitionSettings settings)
Recognizes ID card with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. instance. |
settings | IDCardRecognitionSettings | IDCardRecognitionSettings. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
RecognizeInvoice(OcrInput input, InvoiceRecognitionSettings settings)
public ArrayList<RecognitionResult> RecognizeInvoice(OcrInput input, InvoiceRecognitionSettings settings)
Recognizes invoice with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. instance. |
settings | InvoiceRecognitionSettings | InvoiceRecognitionSettings. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
RecognizePassport(OcrInput input, PassportRecognitionSettings settings)
public ArrayList<RecognitionResult> RecognizePassport(OcrInput input, PassportRecognitionSettings settings)
Recognizes passport with the ability to specify. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. instance. |
settings | PassportRecognitionSettings | PassportRecognitionSettings. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
RecognizeReceipt(OcrInput input, ReceiptRecognitionSettings settings)
public ArrayList<RecognitionResult> RecognizeReceipt(OcrInput input, ReceiptRecognitionSettings settings)
Recognizes receipts with the ability to specify Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. instance. |
settings | ReceiptRecognitionSettings | ReceiptRecognitionSettings. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
RecognizeStreetPhoto(OcrInput input)
public ArrayList<RecognitionResult> RecognizeStreetPhoto(OcrInput input)
Recognizes text on street photos. Extract text from street photos, traffic camera images, ID cards, driver licenses, and other images with sparse text and noisy/colored backgrounds. Supports GIF, PNG, JPEG, WBMP, TIFF, JFIF, TIFF, PDF, InputStream, BufferedImage, folder, array, zip archive, URL, base64.
Parameters:
Parameter | Type | Description |
---|---|---|
input | OcrInput | OcrInput. The container with sources.. |
Returns: java.util.ArrayList<com.aspose.ocr.RecognitionResult> - RecognitionResult list with images recognition results RecognitionResult
SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList results)
public static void SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList<RecognitionResult> results)
Allows to get multipage document from list of RecognitionResult objects.
Parameters:
Parameter | Type | Description |
---|---|---|
stream | java.io.OutputStream | OutputStream for saving recognition result in the selected format. |
saveFormat | Format | Document format (Docx, Txt, Pdf, PdfNoImg, Xlsx, Xml, Json, Rtf). |
results | java.util.ArrayList<com.aspose.ocr.RecognitionResult> | List of RecognitionResult. objects. |
SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList results, String embeddedFontPath)
public static void SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList<RecognitionResult> results, String embeddedFontPath)
Allows to get multipage document from list of RecognitionResult objects.
Parameters:
Parameter | Type | Description |
---|---|---|
stream | java.io.OutputStream | OutputStream for saving recognition result in the selected format. |
saveFormat | Format | Document format (Docx, Txt, Pdf, PdfNoImg, Xlsx, Xml, Json, Rtf). |
results | java.util.ArrayList<com.aspose.ocr.RecognitionResult> | List of RecognitionResult. objects. |
embeddedFontPath | java.lang.String | Optionally. Full path to the user font. |
SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList results, String embeddedFontPath, PdfOptimizationMode optimizePdf)
public static void SaveMultipageDocument(OutputStream stream, Format saveFormat, ArrayList<RecognitionResult> results, String embeddedFontPath, PdfOptimizationMode optimizePdf)
Allows to get multipage document from list of RecognitionResult objects.
Parameters:
Parameter | Type | Description |
---|---|---|
stream | java.io.OutputStream | OutputStream for saving recognition result in the selected format. |
saveFormat | Format | Document format (Docx, Txt, Pdf, PdfNoImg, Xlsx, Xml, Json, Rtf). |
results | java.util.ArrayList<com.aspose.ocr.RecognitionResult> | List of RecognitionResult. objects. |
embeddedFontPath | java.lang.String | Optionally. Full path to the user font. |
optimizePdf | PdfOptimizationMode | Reduce the PDF file size by lowering the quality of background images. By default, the original image quality is preserved. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList results)
public static void SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList<RecognitionResult> results)
Allows to get multipage document from list of RecognitionResult objects.
Parameters:
Parameter | Type | Description |
---|---|---|
fullFileName | java.lang.String | Filename with a path for saving recognition result in the selected format. |
saveFormat | Format | Document format (Docx, Txt, Pdf, Xlsx, Xml, Json). |
results | java.util.ArrayList<com.aspose.ocr.RecognitionResult> | List of RecognitionResult. objects. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList results, SpellCheck.SpellCheckLanguage language)
public static void SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList<RecognitionResult> results, SpellCheck.SpellCheckLanguage language)
Allows to get multipage document from list of RecognitionResult objects with spell-check correction.
Parameters:
Parameter | Type | Description |
---|---|---|
fullFileName | java.lang.String | Filename with a path for saving recognition result in the selected format. |
saveFormat | Format | Document format (Docx, Txt, Pdf, Xlsx, Xml, Json). |
results | java.util.ArrayList<com.aspose.ocr.RecognitionResult> | List of RecognitionResult. objects. |
language | SpellCheckLanguage | SpellCheckLanguage enum value. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList results, String embeddedFontPath)
public static void SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList<RecognitionResult> results, String embeddedFontPath)
Allows to get multipage document from list of RecognitionResult objects.
Parameters:
Parameter | Type | Description |
---|---|---|
fullFileName | java.lang.String | Filename with a path for saving recognition result in the selected format. |
saveFormat | Format | Document format (Docx, Txt, Pdf, Xlsx, Xml, Json). |
results | java.util.ArrayList<com.aspose.ocr.RecognitionResult> | List of RecognitionResult. objects. |
embeddedFontPath | java.lang.String | Optionally. Full path to the user font. |
SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList results, String embeddedFontPath, PdfOptimizationMode optimizePdf)
public static void SaveMultipageDocument(String fullFileName, Format saveFormat, ArrayList<RecognitionResult> results, String embeddedFontPath, PdfOptimizationMode optimizePdf)
Allows to get multipage document from list of RecognitionResult objects.
Parameters:
Parameter | Type | Description |
---|---|---|
fullFileName | java.lang.String | Filename with a path for saving recognition result in the selected format. |
saveFormat | Format | Document format (Docx, Txt, Pdf, Xlsx, Xml, Json). |
results | java.util.ArrayList<com.aspose.ocr.RecognitionResult> | List of RecognitionResult. objects. |
embeddedFontPath | java.lang.String | Optionally. Full path to the user font. |
optimizePdf | PdfOptimizationMode | Reduce the PDF file size by lowering the quality of background images. By default, the original image quality is preserved. |