MLKitEntityExtraction Framework Reference

  • MoneyEntity objects represent monetary values extracted from text.

  • The unnormalizedCurrency property provides the original currency text as detected.

  • The monetary value is split into integerPart and fractionalPart for numerical representation.

  • Direct initialization of MoneyEntity instances is not allowed.

MoneyEntity

class MoneyEntity : NSObject

A money entity extracted from text.

  • The currency part of the detected annotation. No formatting is applied so this will return a subset of the initial string.

    Declaration

    Swift

    var unnormalizedCurrency: String { get }
  • The integer part of the detected annotation. This is the integer written to the left of the decimal separator.

    Declaration

    Swift

    var integerPart: Int { get }
  • The fractional part of the detected annotation. This is the integer written to the right of the decimal separator.

    Declaration

    Swift

    var fractionalPart: Int { get }
  • Unavailable.