toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final result$data = <String, dynamic>{};
  if (_$data.containsKey('picture')) {
    final l$picture = picture;
    result$data['picture'] = l$picture?.toJson();
  }
  if (_$data.containsKey('quizzType')) {
    final l$quizzType = quizzType;
    result$data['quizzType'] = l$quizzType == null
        ? null
        : toJson$Enum$QuestionTypeEnum(l$quizzType);
  }
  if (_$data.containsKey('choices')) {
    final l$choices = choices;
    result$data['choices'] = l$choices?.map((e) => e.toJson()).toList();
  }
  return result$data;
}