toJson method
override
Implementation
@override
Map<String, dynamic> toJson() {
return {
"detectorType": detectorType.name,
if (flashEnabled != null) "flashEnabled": flashEnabled,
if (hardwareButtonsEnabled != null)
"hardwareButtonsEnabled": hardwareButtonsEnabled,
"detectionEnabled": detectionEnabled,
if (cameraZoomFactor != null) "cameraZoomFactor": cameraZoomFactor,
if (cameraZoomRange != null) "cameraZoomRange": cameraZoomRange?.toJson(),
if (cameraModule != null) "cameraModule": cameraModule!.name,
if (minFocusDistanceLock != null)
"minFocusDistanceLock": minFocusDistanceLock,
if (finder != null) "finder": finder?.toJson(),
"scannerConfiguration": scannerConfiguration.toJson(),
if (overlayConfiguration != null)
"overlayConfiguration": overlayConfiguration?.toJson(),
"scannerResolution": cameraLiveScannerResolution.name,
};
}