toJson method
Implementation
@visibleForTesting
Map<String, dynamic> toJson() => {
"scenario": scenario?.value,
"onlineProcessingConfig": onlineProcessingConfig?.toJson(),
"oneShotIdentification": oneShotIdentification,
"livePortrait": _imageToBase64(livePortrait),
"extPortrait": _imageToBase64(extPortrait),
"image": _imageToBase64(image),
"data": _toBase64(data),
"images": images?.map((e) => _imageToBase64(e)).toList(),
"imageInputData": imageInputData?.map((e) => e.toJson()).toList(),
}.clearNulls();