toJson method
Converts the VideoRecordedEvent instance into a Map instance that can be serialized to JSON.
Implementation
Map<String, dynamic> toJson() => <String, Object?>{
'cameraId': cameraId,
'path': file.path,
'maxVideoDuration': maxVideoDuration?.inMilliseconds
};