scanCard static method

Future<CardDetails?> scanCard({
  1. CardScanOptions? scanOptions,
})

Implementation

static Future<CardDetails?> scanCard({CardScanOptions? scanOptions}) async {
  scanOptions ??= const CardScanOptions();
  final scanResult = await _channel.invokeMapMethod<String, String>(
      _scan_card, scanOptions.map);
  print("method channel : GOT VALUE FROM METHOD CHANNEL : $scanResult");

  if (scanResult != null) return CardDetails.fromMap(scanResult);

  return null;
}