GroupDocs.Parser for Java 23.11 Release Notes
This page contains release notes for GroupDocs.Parser for Java 23.11
Full List of Issues Covering all Changes in this Release
Key | Summary | Category |
---|---|---|
PARSERNET-2206 | Improve template parsing functionality | Improvement |
PARSERNET-2187 | Implement the support for Kindle documents formats | Feature |
Public API and Backward Incompatible Changes
Improve template parsing functionality
Description
This improvement allows to set case of the field names.
Public API changes
FieldData public class was updated with changes as follows:
- Added FieldData(String name, PageArea pageArea, boolean useUpperCaseName) constructor
- Added FieldData(String name, PageArea pageArea, FieldData linkedField, boolean useUpperCaseName) constructor
- Added UseUpperCaseName property
TemplateItem public class was updated with changes as follows:
- Added UseUpperCaseName property
TemplateLinkedPosition public class was updated with changes as follows:
- Added TemplateLinkedPosition(String linkedFieldName, Size searchArea, TemplateLinkedPositionEdges edges, boolean autoScale, boolean useUpperCaseName) constructor
Usage
The following example shows how to create instances of template item or field data without name case converting:
// Create an instance of barcode field
TemplateBarcode barcode = new TemplateBarcode(rectangle, "FieldName", 1, false);
// Create an instance of text field
TemplateField field = new TemplateField(position, "FieldName", 1, false);
// Create an instance of table field with layout
TemplateTable table = new TemplateTable(layout, "TableName", null, false);
// Create an instance of table field with table parameters
TemplateTable table = new TemplateTable(parameters, "TableName", 1, false);
// Create an instance of template linked position
TemplateLinkedPosition position = new TemplateLinkedPosition("Name", size, edges, false, false);
// Create an instance of field data
FieldData field = new FieldData("Name", pageArea, false);
Implement the support for Kindle documents formats
Description
This feature adds the ability to exract a text from MOBI and AZW3 ebook formats.
Public API changes
FileType public class was updated with changes as follows:
Usage
The following example shows how to extract a text from MOBI ebook:
// Create an instance of Parser class
try (Parser parser = new Parser("book.mobi")) {
// Extract a text into the reader
try (TextReader reader = parser.getText()) {
// Print a text from the document
// If text extraction isn't supported, a reader is null
System.out.println(reader == null ? "Text extraction isn't supported" : reader.readToEnd());
}
}