toJson method
Implementation
@override
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = {};
if (candidates != null) {
data['candidates'] = candidates?.map((x) => x.toJson()).toList();
}
if (promptFeedback != null) {
data['promptFeedback'] = promptFeedback?.toJson();
}
return data;
}