BarcodeArResponsiveAnnotation constructor

  1. @Deprecated('Use the constructor that accepts an annotationsByThreshold map instead. Will be removed in 9.0.')
BarcodeArResponsiveAnnotation(
  1. Barcode _barcode,
  2. BarcodeArInfoAnnotation? closeUpAnnotation,
  3. BarcodeArInfoAnnotation? farAwayAnnotation
)

Constructs a new responsive annotation with the given barcode and annotation variations.

Added in version 8.2.0

Implementation

@Deprecated('Use the constructor that accepts an annotationsByThreshold map instead. Will be removed in 9.0.')
BarcodeArResponsiveAnnotation(
    this._barcode, BarcodeArInfoAnnotation? closeUpAnnotation, BarcodeArInfoAnnotation? farAwayAnnotation)
    : _annotationsByThreshold = _validate({
        BarcodeArDefaults.view.defaultResponsiveAnnotationThreshold: farAwayAnnotation,
        1.0: closeUpAnnotation,
      }),
      _usesLegacyTwoStateApi = true,
      super._(BarcodeArDefaults.view.defaultResponsiveAnnotationTrigger, 'barcodeArResponsiveAnnotation');