getDecodingSpeed property

Future<DecodingSpeed> getDecodingSpeed

Retrieves the current decoding speed setting for barcode scanning.

Returns a Future that completes with a DecodingSpeed enum value representing the decoding speed.

Example usage:

DecodingSpeed speed = await _barkoder.getDecodingSpeed;
print('Decoding speed: $speed');

Implementation

Future<DecodingSpeed> get getDecodingSpeed async {
  if (_isBarkoderViewNotMounted) {
    return Future.error(PlatformException(
        code: BarkoderErrors.barkoderViewNotMounted,
        message: BarkoderErrors.barkodeViewNotMountedDesc));
  }

  return await _methodChannel.invokeMethod('getDecodingSpeed').then((index) {
    return DecodingSpeed.values[index];
  });
}