TextZonesUnit
The TextZonesUnit class represents a unit that contains text zones. It is derived from IntermediateResultUnit class and provides methods to retrieve the count and details of text zones.
Definition
Namespace: com.dynamsoft.core.intermediate_results
public class TextZonesUnit extends IntermediateResultUnit
Methods
| Method | Description |
|---|---|
getCount |
Gets the number of text zones. |
getTextZone |
Gets the text zone at the specified index. |
getTextZones |
Gets all text zones. |
removeAllTextZones |
Removes all text zones from the unit. |
removeTextZone |
Removes the text zone at the specified index. |
addTextZone |
Adds a text zone to the unit. |
setTextZone |
Sets the text zone at the specified index. |
getCount
Gets the number of text zones in the unit.
int getCount()
Return value
Returns the number of text zones in the unit.
getTextZone
Gets the text zone at the specified index.
TextZone getTextZone(int index) throws CoreException
Parameters
index The index of the text zone.
Return Value
Returns the TextZone object at the specified index.
Exception
See Also
getTextZones
Gets all text zones.
TextZone[] getTextZones()
Return Value
Returns an array of TextZone objects representing all text zones.
See Also
removeAllTextZones
Removes all text zones from the unit.
void removeAllTextZones()
removeTextZone
Removes the text zone at the specified index.
void removeTextZone(int index) throws CoreException
Parameters
index The index of the text zone to remove.
Exception
addTextZone
Adds a text zone to the unit.
void addTextZone(TextZone textZone) throws CoreException
void addTextZone(TextZone textZone, double[] matrixToOriginalImage) throws CoreException
Parameters
textZone The text zone to add.
matrixToOriginalImage The transform matrix to original image. The array length must be 9.
Exception
See Also
setTextZone
Sets the text zone at the specified index.
void setTextZone(int index, TextZone textZone) throws CoreException
void setTextZone(int index, TextZone textZone, double[] matrixToOriginalImage) throws CoreException
Parameters
index The index of the text zone to set.
textZone The text zone to set.
matrixToOriginalImage The transform matrix to original image. The array length must be 9.
Exception
See Also