FloatType
A float value paired with an OCR confidence score.
Package: com.microblink.core
Declaration
class FloatType : Parcelable
Constructors:
FloatType(value: Float)
FloatType(value: Float, confidence: Float)
Quick Reference
Properties
| Property | Description |
|---|---|
value() | The raw float value |
confidence() | OCR or parsing confidence score |
decimal() | Value rounded to 2 decimal places |
toBigDecimal() | Non-null BigDecimal representation |
Properties
value()
fun value(): Float
The raw float value.
confidence()
fun confidence(): Float
OCR or parsing confidence score.
decimal()
fun decimal(): Double
fun decimal(scale: Int): Double
fun decimal(scale: Int, mode: RoundingMode): Double
Returns the value rounded to 2 decimal places (default), a given scale, or with an explicit RoundingMode. Suitable for currency display.
toBigDecimal()
fun toBigDecimal(): BigDecimal
Non-null BigDecimal representation of the value.