Package io.scanbot.sdk.ocr.model
Class OcrElement
-
- All Implemented Interfaces:
-
android.os.Parcelable
public class OcrElement implements Parcelable
Base class for units of text, e.g. glyphs, words, lines, blocks, pages.
-
-
Method Summary
Modifier and Type Method Description abstract String
getText()
The recognized text. abstract Double
getConfidence()
Text confidence. abstract List<PointF>
getRoi()
Quad where the text was found in image coordinates. abstract String
get_type()
abstract OcrElement
clone()
abstract JSONObject
toJson(ToJsonConfiguration config)
final static OcrElement
invoke(Map<String, Object> source)
final static Glyph
glyph(String text, Double confidence, List<PointF> roi)
final static Word
word(String text, Double confidence, List<PointF> roi, List<Glyph> glyphs)
final static Line
line(String text, Double confidence, List<PointF> roi, List<Word> words)
final static Block
block(String text, Double confidence, List<PointF> roi, List<Line> lines)
final static Page
page(String text, Double confidence, List<PointF> roi, List<Block> blocks)
-
-
Method Detail
-
getConfidence
abstract Double getConfidence()
Text confidence. Range is 0-1.
-
getRoi
abstract List<PointF> getRoi()
Quad where the text was found in image coordinates. The order of the points is clockwise starting from the top left.
-
clone
abstract OcrElement clone()
-
toJson
abstract JSONObject toJson(ToJsonConfiguration config)
-
invoke
final static OcrElement invoke(Map<String, Object> source)
-
-
-
-