toJson method
Implementation
Map<String, dynamic> toJson() {
return {
"detectorType": detectorType.name,
if (barcodeFormatConfigurations != null)
"barcodeFormatConfigurations":
barcodeFormatConfigurations?.map((e) => e.toJson()).toList(),
if (acceptedDocumentFormats != null)
"acceptedDocumentFormats":
acceptedDocumentFormats?.map((e) => e.name).toList(),
if (engineMode != null) "engineMode": engineMode!.name,
if (accumulationConfig != null)
"accumulationConfig": accumulationConfig?.toJson(),
if (returnBarcodeImage != null) "returnBarcodeImage": returnBarcodeImage,
if (onlyAcceptDocuments != null)
"onlyAcceptDocuments": onlyAcceptDocuments,
};
}